/* Auto-height textareas - https://github.com/alexdunphy/flexible-textareas */
(function (b) {
    function a(c) {
        this.$textarea = b(c);
        this._init()
    }

    a.prototype = {_init: function () {
        var c = this;
        this.$textarea.wrap('<div class="flex-text-wrap" />').before("<pre><span /><br /><br /></pre>");
        this.$span = this.$textarea.prev().find("span");
        this.$textarea.on("input propertychange", function () {
            c._mirror()
        });
        if (b.browser.msie) {
            if (b.browser.version > 8) {
                this.$textarea.on("keyup change", function () {
                    c._mirror()
                })
            } else {
                if (b.browser.version < 8) {
                    b.valHooks.textarea = {get: function (d) {
                        return d.value.replace(/\r?\n/g, "\r\n")
                    }}
                }
            }
        }
        this._mirror()
    }, _mirror: function () {
        this.$span.text(this.$textarea.val())
    }};
    b.fn.flexText = function () {
        return this.each(function () {
            if (!b.data(this, "flexText")) {
                b.data(this, "flexText", new a(this))
            }
        })
    }
})(jQuery);


/*
 * jPlayer Plugin for jQuery JavaScript Library
 * http://www.jplayer.org
 *
 * Copyright (c) 2009 - 2011 Happyworm Ltd
 * Dual licensed under the MIT and GPL licenses.
 *  - http://www.opensource.org/licenses/mit-license.php
 *  - http://www.gnu.org/copyleft/gpl.html
 *
 * Author: Mark J Panaghiston
 * Version: 2.1.0
 * Date: 1st September 2011
 */

(function (b, f) {
    b.fn.jPlayer = function (a) {
        var c = typeof a === "string", d = Array.prototype.slice.call(arguments, 1), e = this, a = !c && d.length ? b.extend.apply(null, [!0, a].concat(d)) : a;
        if (c && a.charAt(0) === "_")return e;
        c ? this.each(function () {
            var c = b.data(this, "jPlayer"), h = c && b.isFunction(c[a]) ? c[a].apply(c, d) : c;
            if (h !== c && h !== f)return e = h, !1
        }) : this.each(function () {
            var c = b.data(this, "jPlayer");
            c ? c.option(a || {}) : b.data(this, "jPlayer", new b.jPlayer(a, this))
        });
        return e
    };
    b.jPlayer = function (a, c) {
        if (arguments.length) {
            this.element =
                b(c);
            this.options = b.extend(!0, {}, this.options, a);
            var d = this;
            this.element.bind("remove.jPlayer", function () {
                d.destroy()
            });
            this._init()
        }
    };
    b.jPlayer.emulateMethods = "load play pause";
    b.jPlayer.emulateStatus = "src readyState networkState currentTime duration paused ended playbackRate";
    b.jPlayer.emulateOptions = "muted volume";
    b.jPlayer.reservedEvent = "ready flashreset resize repeat error warning";
    b.jPlayer.event = {ready: "jPlayer_ready", flashreset: "jPlayer_flashreset", resize: "jPlayer_resize", repeat: "jPlayer_repeat",
        click: "jPlayer_click", error: "jPlayer_error", warning: "jPlayer_warning", loadstart: "jPlayer_loadstart", progress: "jPlayer_progress", suspend: "jPlayer_suspend", abort: "jPlayer_abort", emptied: "jPlayer_emptied", stalled: "jPlayer_stalled", play: "jPlayer_play", pause: "jPlayer_pause", loadedmetadata: "jPlayer_loadedmetadata", loadeddata: "jPlayer_loadeddata", waiting: "jPlayer_waiting", playing: "jPlayer_playing", canplay: "jPlayer_canplay", canplaythrough: "jPlayer_canplaythrough", seeking: "jPlayer_seeking", seeked: "jPlayer_seeked",
        timeupdate: "jPlayer_timeupdate", ended: "jPlayer_ended", ratechange: "jPlayer_ratechange", durationchange: "jPlayer_durationchange", volumechange: "jPlayer_volumechange"};
    b.jPlayer.htmlEvent = "loadstart,abort,emptied,stalled,loadedmetadata,loadeddata,canplay,canplaythrough,ratechange".split(",");
    b.jPlayer.pause = function () {
        b.each(b.jPlayer.prototype.instances, function (a, b) {
            b.data("jPlayer").status.srcSet && b.jPlayer("pause")
        })
    };
    b.jPlayer.timeFormat = {showHour: !1, showMin: !0, showSec: !0, padHour: !1, padMin: !0, padSec: !0,
        sepHour: ":", sepMin: ":", sepSec: ""};
    b.jPlayer.convertTime = function (a) {
        var c = new Date(a * 1E3), d = c.getUTCHours(), a = c.getUTCMinutes(), c = c.getUTCSeconds(), d = b.jPlayer.timeFormat.padHour && d < 10 ? "0" + d : d, a = b.jPlayer.timeFormat.padMin && a < 10 ? "0" + a : a, c = b.jPlayer.timeFormat.padSec && c < 10 ? "0" + c : c;
        return(b.jPlayer.timeFormat.showHour ? d + b.jPlayer.timeFormat.sepHour : "") + (b.jPlayer.timeFormat.showMin ? a + b.jPlayer.timeFormat.sepMin : "") + (b.jPlayer.timeFormat.showSec ? c + b.jPlayer.timeFormat.sepSec : "")
    };
    b.jPlayer.uaBrowser =
        function (a) {
            var a = a.toLowerCase(), b = /(opera)(?:.*version)?[ \/]([\w.]+)/, d = /(msie) ([\w.]+)/, e = /(mozilla)(?:.*? rv:([\w.]+))?/, a = /(webkit)[ \/]([\w.]+)/.exec(a) || b.exec(a) || d.exec(a) || a.indexOf("compatible") < 0 && e.exec(a) || [];
            return{browser: a[1] || "", version: a[2] || "0"}
        };
    b.jPlayer.uaPlatform = function (a) {
        var b = a.toLowerCase(), d = /(android)/, e = /(mobile)/, a = /(ipad|iphone|ipod|android|blackberry|playbook|windows ce|webos)/.exec(b) || [], b = /(ipad|playbook)/.exec(b) || !e.exec(b) && d.exec(b) || [];
        a[1] && (a[1] = a[1].replace(/\s/g,
            "_"));
        return{platform: a[1] || "", tablet: b[1] || ""}
    };
    b.jPlayer.browser = {};
    b.jPlayer.platform = {};
    var i = b.jPlayer.uaBrowser(navigator.userAgent);
    if (i.browser)b.jPlayer.browser[i.browser] = !0, b.jPlayer.browser.version = i.version;
    i = b.jPlayer.uaPlatform(navigator.userAgent);
    if (i.platform)b.jPlayer.platform[i.platform] = !0, b.jPlayer.platform.mobile = !i.tablet, b.jPlayer.platform.tablet = !!i.tablet;
    b.jPlayer.prototype = {count: 0, version: {script: "2.1.0", needFlash: "2.1.0", flash: "unknown"}, options: {swfPath: "js", solution: "html, flash",
        supplied: "mp3", preload: "metadata", volume: 0.8, muted: !1, wmode: "opaque", backgroundColor: "#000000", cssSelectorAncestor: "#jp_container_1", cssSelector: {videoPlay: ".jp-video-play", play: ".jp-play", pause: ".jp-pause", stop: ".jp-stop", seekBar: ".jp-seek-bar", playBar: ".jp-play-bar", mute: ".jp-mute", unmute: ".jp-unmute", volumeBar: ".jp-volume-bar", volumeBarValue: ".jp-volume-bar-value", volumeMax: ".jp-volume-max", currentTime: ".jp-current-time", duration: ".jp-duration", fullScreen: ".jp-full-screen", restoreScreen: ".jp-restore-screen",
            repeat: ".jp-repeat", repeatOff: ".jp-repeat-off", gui: ".jp-gui", noSolution: ".jp-no-solution"}, fullScreen: !1, autohide: {restored: !1, full: !0, fadeIn: 200, fadeOut: 600, hold: 1E3}, loop: !1, repeat: function (a) {
            a.jPlayer.options.loop ? b(this).unbind(".jPlayerRepeat").bind(b.jPlayer.event.ended + ".jPlayer.jPlayerRepeat", function () {
                b(this).jPlayer("play")
            }) : b(this).unbind(".jPlayerRepeat")
        }, nativeVideoControls: {}, noFullScreen: {msie: /msie [0-6]/, ipad: /ipad.*?os [0-4]/, iphone: /iphone/, ipod: /ipod/, android_pad: /android [0-3](?!.*?mobile)/,
            android_phone: /android.*?mobile/, blackberry: /blackberry/, windows_ce: /windows ce/, webos: /webos/}, noVolume: {ipad: /ipad/, iphone: /iphone/, ipod: /ipod/, android_pad: /android(?!.*?mobile)/, android_phone: /android.*?mobile/, blackberry: /blackberry/, windows_ce: /windows ce/, webos: /webos/, playbook: /playbook/}, verticalVolume: !1, idPrefix: "jp", noConflict: "jQuery", emulateHtml: !1, errorAlerts: !1, warningAlerts: !1}, optionsAudio: {size: {width: "0px", height: "0px", cssClass: ""}, sizeFull: {width: "0px", height: "0px", cssClass: ""}},
        optionsVideo: {size: {width: "480px", height: "270px", cssClass: "jp-video-270p"}, sizeFull: {width: "100%", height: "100%", cssClass: "jp-video-full"}}, instances: {}, status: {src: "", media: {}, paused: !0, format: {}, formatType: "", waitForPlay: !0, waitForLoad: !0, srcSet: !1, video: !1, seekPercent: 0, currentPercentRelative: 0, currentPercentAbsolute: 0, currentTime: 0, duration: 0, readyState: 0, networkState: 0, playbackRate: 1, ended: 0}, internal: {ready: !1}, solution: {html: !0, flash: !0}, format: {mp3: {codec: 'audio/mpeg; codecs="mp3"', flashCanPlay: !0,
            media: "audio"}, m4a: {codec: 'audio/mp4; codecs="mp4a.40.2"', flashCanPlay: !0, media: "audio"}, oga: {codec: 'audio/ogg; codecs="vorbis"', flashCanPlay: !1, media: "audio"}, wav: {codec: 'audio/wav; codecs="1"', flashCanPlay: !1, media: "audio"}, webma: {codec: 'audio/webm; codecs="vorbis"', flashCanPlay: !1, media: "audio"}, fla: {codec: "audio/x-flv", flashCanPlay: !0, media: "audio"}, m4v: {codec: 'video/mp4; codecs="avc1.42E01E, mp4a.40.2"', flashCanPlay: !0, media: "video"}, ogv: {codec: 'video/ogg; codecs="theora, vorbis"', flashCanPlay: !1,
            media: "video"}, webmv: {codec: 'video/webm; codecs="vorbis, vp8"', flashCanPlay: !1, media: "video"}, flv: {codec: "video/x-flv", flashCanPlay: !0, media: "video"}}, _init: function () {
            var a = this;
            this.element.empty();
            this.status = b.extend({}, this.status);
            this.internal = b.extend({}, this.internal);
            this.internal.domNode = this.element.get(0);
            this.formats = [];
            this.solutions = [];
            this.require = {};
            this.htmlElement = {};
            this.html = {};
            this.html.audio = {};
            this.html.video = {};
            this.flash = {};
            this.css = {};
            this.css.cs = {};
            this.css.jq = {};
            this.ancestorJq =
                [];
            this.options.volume = this._limitValue(this.options.volume, 0, 1);
            b.each(this.options.supplied.toLowerCase().split(","), function (c, d) {
                var e = d.replace(/^\s+|\s+$/g, "");
                if (a.format[e]) {
                    var f = !1;
                    b.each(a.formats, function (a, b) {
                        if (e === b)return f = !0, !1
                    });
                    f || a.formats.push(e)
                }
            });
            b.each(this.options.solution.toLowerCase().split(","), function (c, d) {
                var e = d.replace(/^\s+|\s+$/g, "");
                if (a.solution[e]) {
                    var f = !1;
                    b.each(a.solutions, function (a, b) {
                        if (e === b)return f = !0, !1
                    });
                    f || a.solutions.push(e)
                }
            });
            this.internal.instance =
                "jp_" + this.count;
            this.instances[this.internal.instance] = this.element;
            this.element.attr("id") || this.element.attr("id", this.options.idPrefix + "_jplayer_" + this.count);
            this.internal.self = b.extend({}, {id: this.element.attr("id"), jq: this.element});
            this.internal.audio = b.extend({}, {id: this.options.idPrefix + "_audio_" + this.count, jq: f});
            this.internal.video = b.extend({}, {id: this.options.idPrefix + "_video_" + this.count, jq: f});
            this.internal.flash = b.extend({}, {id: this.options.idPrefix + "_flash_" + this.count, jq: f, swf: this.options.swfPath +
                (this.options.swfPath.toLowerCase().slice(-4) !== ".swf" ? (this.options.swfPath && this.options.swfPath.slice(-1) !== "/" ? "/" : "") + "jplayer.swf" : "")});
            this.internal.poster = b.extend({}, {id: this.options.idPrefix + "_poster_" + this.count, jq: f});
            b.each(b.jPlayer.event, function (b, c) {
                a.options[b] !== f && (a.element.bind(c + ".jPlayer", a.options[b]), a.options[b] = f)
            });
            this.require.audio = !1;
            this.require.video = !1;
            b.each(this.formats, function (b, c) {
                a.require[a.format[c].media] = !0
            });
            this.options = this.require.video ? b.extend(!0,
                {}, this.optionsVideo, this.options) : b.extend(!0, {}, this.optionsAudio, this.options);
            this._setSize();
            this.status.nativeVideoControls = this._uaBlocklist(this.options.nativeVideoControls);
            this.status.noFullScreen = this._uaBlocklist(this.options.noFullScreen);
            this.status.noVolume = this._uaBlocklist(this.options.noVolume);
            this._restrictNativeVideoControls();
            this.htmlElement.poster = document.createElement("img");
            this.htmlElement.poster.id = this.internal.poster.id;
            this.htmlElement.poster.onload = function () {
                (!a.status.video ||
                    a.status.waitForPlay) && a.internal.poster.jq.show()
            };
            this.element.append(this.htmlElement.poster);
            this.internal.poster.jq = b("#" + this.internal.poster.id);
            this.internal.poster.jq.css({width: this.status.width, height: this.status.height});
            this.internal.poster.jq.hide();
            this.internal.poster.jq.bind("click.jPlayer", function () {
                a._trigger(b.jPlayer.event.click)
            });
            this.html.audio.available = !1;
            if (this.require.audio)this.htmlElement.audio = document.createElement("audio"), this.htmlElement.audio.id = this.internal.audio.id,
                this.html.audio.available = !!this.htmlElement.audio.canPlayType && this._testCanPlayType(this.htmlElement.audio);
            this.html.video.available = !1;
            if (this.require.video)this.htmlElement.video = document.createElement("video"), this.htmlElement.video.id = this.internal.video.id, this.html.video.available = !!this.htmlElement.video.canPlayType && this._testCanPlayType(this.htmlElement.video);
            this.flash.available = this._checkForFlash(10);
            this.html.canPlay = {};
            this.flash.canPlay = {};
            b.each(this.formats, function (b, c) {
                a.html.canPlay[c] =
                    a.html[a.format[c].media].available && "" !== a.htmlElement[a.format[c].media].canPlayType(a.format[c].codec);
                a.flash.canPlay[c] = a.format[c].flashCanPlay && a.flash.available
            });
            this.html.desired = !1;
            this.flash.desired = !1;
            b.each(this.solutions, function (c, d) {
                if (c === 0)a[d].desired = !0; else {
                    var e = !1, f = !1;
                    b.each(a.formats, function (b, c) {
                        a[a.solutions[0]].canPlay[c] && (a.format[c].media === "video" ? f = !0 : e = !0)
                    });
                    a[d].desired = a.require.audio && !e || a.require.video && !f
                }
            });
            this.html.support = {};
            this.flash.support = {};
            b.each(this.formats,
                function (b, c) {
                    a.html.support[c] = a.html.canPlay[c] && a.html.desired;
                    a.flash.support[c] = a.flash.canPlay[c] && a.flash.desired
                });
            this.html.used = !1;
            this.flash.used = !1;
            b.each(this.solutions, function (c, d) {
                b.each(a.formats, function (b, c) {
                    if (a[d].support[c])return a[d].used = !0, !1
                })
            });
            this._resetActive();
            this._resetGate();
            this._cssSelectorAncestor(this.options.cssSelectorAncestor);
            !this.html.used && !this.flash.used ? (this._error({type: b.jPlayer.error.NO_SOLUTION, context: "{solution:'" + this.options.solution + "', supplied:'" +
                this.options.supplied + "'}", message: b.jPlayer.errorMsg.NO_SOLUTION, hint: b.jPlayer.errorHint.NO_SOLUTION}), this.css.jq.noSolution.length && this.css.jq.noSolution.show()) : this.css.jq.noSolution.length && this.css.jq.noSolution.hide();
            if (this.flash.used) {
                var c, d = "jQuery=" + encodeURI(this.options.noConflict) + "&id=" + encodeURI(this.internal.self.id) + "&vol=" + this.options.volume + "&muted=" + this.options.muted;
                if (b.browser.msie && Number(b.browser.version) <= 8) {
                    d = ['<param name="movie" value="' + this.internal.flash.swf +
                        '" />', '<param name="FlashVars" value="' + d + '" />', '<param name="allowScriptAccess" value="always" />', '<param name="bgcolor" value="' + this.options.backgroundColor + '" />', '<param name="wmode" value="' + this.options.wmode + '" />'];
                    c = document.createElement('<object id="' + this.internal.flash.id + '" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="0" height="0"></object>');
                    for (var e = 0; e < d.length; e++)c.appendChild(document.createElement(d[e]))
                } else e = function (a, b, c) {
                    var d = document.createElement("param");
                    d.setAttribute("name", b);
                    d.setAttribute("value", c);
                    a.appendChild(d)
                }, c = document.createElement("object"), c.setAttribute("id", this.internal.flash.id), c.setAttribute("data", this.internal.flash.swf), c.setAttribute("type", "application/x-shockwave-flash"), c.setAttribute("width", "1"), c.setAttribute("height", "1"), e(c, "flashvars", d), e(c, "allowscriptaccess", "always"), e(c, "bgcolor", this.options.backgroundColor), e(c, "wmode", this.options.wmode);
                this.element.append(c);
                this.internal.flash.jq = b(c)
            }
            if (this.html.used) {
                if (this.html.audio.available)this._addHtmlEventListeners(this.htmlElement.audio,
                    this.html.audio), this.element.append(this.htmlElement.audio), this.internal.audio.jq = b("#" + this.internal.audio.id);
                if (this.html.video.available)this._addHtmlEventListeners(this.htmlElement.video, this.html.video), this.element.append(this.htmlElement.video), this.internal.video.jq = b("#" + this.internal.video.id), this.status.nativeVideoControls ? this.internal.video.jq.css({width: this.status.width, height: this.status.height}) : this.internal.video.jq.css({width: "0px", height: "0px"}), this.internal.video.jq.bind("click.jPlayer",
                    function () {
                        a._trigger(b.jPlayer.event.click)
                    })
            }
            this.options.emulateHtml && this._emulateHtmlBridge();
            this.html.used && !this.flash.used && setTimeout(function () {
                a.internal.ready = !0;
                a.version.flash = "n/a";
                a._trigger(b.jPlayer.event.repeat);
                a._trigger(b.jPlayer.event.ready)
            }, 100);
            this._updateNativeVideoControls();
            this._updateInterface();
            this._updateButtons(!1);
            this._updateAutohide();
            this._updateVolume(this.options.volume);
            this._updateMute(this.options.muted);
            this.css.jq.videoPlay.length && this.css.jq.videoPlay.hide();
            b.jPlayer.prototype.count++
        }, destroy: function () {
            this.clearMedia();
            this._removeUiClass();
            this.css.jq.currentTime.length && this.css.jq.currentTime.text("");
            this.css.jq.duration.length && this.css.jq.duration.text("");
            b.each(this.css.jq, function (a, b) {
                b.length && b.unbind(".jPlayer")
            });
            this.internal.poster.jq.unbind(".jPlayer");
            this.internal.video.jq && this.internal.video.jq.unbind(".jPlayer");
            this.options.emulateHtml && this._destroyHtmlBridge();
            this.element.removeData("jPlayer");
            this.element.unbind(".jPlayer");
            this.element.empty();
            delete this.instances[this.internal.instance]
        }, enable: function () {
        }, disable: function () {
        }, _testCanPlayType: function (a) {
            try {
                return a.canPlayType(this.format.mp3.codec), !0
            } catch (b) {
                return!1
            }
        }, _uaBlocklist: function (a) {
            var c = navigator.userAgent.toLowerCase(), d = !1;
            b.each(a, function (a, b) {
                if (b && b.test(c))return d = !0, !1
            });
            return d
        }, _restrictNativeVideoControls: function () {
            if (this.require.audio && this.status.nativeVideoControls)this.status.nativeVideoControls = !1, this.status.noFullScreen = !0
        },
        _updateNativeVideoControls: function () {
            if (this.html.video.available && this.html.used)this.htmlElement.video.controls = this.status.nativeVideoControls, this._updateAutohide(), this.status.nativeVideoControls && this.require.video ? (this.internal.poster.jq.hide(), this.internal.video.jq.css({width: this.status.width, height: this.status.height})) : this.status.waitForPlay && this.status.video && (this.internal.poster.jq.show(), this.internal.video.jq.css({width: "0px", height: "0px"}))
        }, _addHtmlEventListeners: function (a, c) {
            var d = this;
            a.preload = this.options.preload;
            a.muted = this.options.muted;
            a.volume = this.options.volume;
            a.addEventListener("progress", function () {
                c.gate && (d._getHtmlStatus(a), d._updateInterface(), d._trigger(b.jPlayer.event.progress))
            }, !1);
            a.addEventListener("timeupdate", function () {
                c.gate && (d._getHtmlStatus(a), d._updateInterface(), d._trigger(b.jPlayer.event.timeupdate))
            }, !1);
            a.addEventListener("durationchange", function () {
                if (c.gate)d.status.duration = this.duration, d._getHtmlStatus(a), d._updateInterface(),
                    d._trigger(b.jPlayer.event.durationchange)
            }, !1);
            a.addEventListener("play", function () {
                c.gate && (d._updateButtons(!0), d._html_checkWaitForPlay(), d._trigger(b.jPlayer.event.play))
            }, !1);
            a.addEventListener("playing", function () {
                c.gate && (d._updateButtons(!0), d._seeked(), d._trigger(b.jPlayer.event.playing))
            }, !1);
            a.addEventListener("pause", function () {
                c.gate && (d._updateButtons(!1), d._trigger(b.jPlayer.event.pause))
            }, !1);
            a.addEventListener("waiting", function () {
                    c.gate && (d._seeking(), d._trigger(b.jPlayer.event.waiting))
                },
                !1);
            a.addEventListener("seeking", function () {
                c.gate && (d._seeking(), d._trigger(b.jPlayer.event.seeking))
            }, !1);
            a.addEventListener("seeked", function () {
                c.gate && (d._seeked(), d._trigger(b.jPlayer.event.seeked))
            }, !1);
            a.addEventListener("volumechange", function () {
                if (c.gate)d.options.volume = a.volume, d.options.muted = a.muted, d._updateMute(), d._updateVolume(), d._trigger(b.jPlayer.event.volumechange)
            }, !1);
            a.addEventListener("suspend", function () {
                c.gate && (d._seeked(), d._trigger(b.jPlayer.event.suspend))
            }, !1);
            a.addEventListener("ended",
                function () {
                    if (c.gate) {
                        if (!b.jPlayer.browser.webkit)d.htmlElement.media.currentTime = 0;
                        d.htmlElement.media.pause();
                        d._updateButtons(!1);
                        d._getHtmlStatus(a, !0);
                        d._updateInterface();
                        d._trigger(b.jPlayer.event.ended)
                    }
                }, !1);
            a.addEventListener("error", function () {
                if (c.gate && (d._updateButtons(!1), d._seeked(), d.status.srcSet))clearTimeout(d.internal.htmlDlyCmdId), d.status.waitForLoad = !0, d.status.waitForPlay = !0, d.status.video && !d.status.nativeVideoControls && d.internal.video.jq.css({width: "0px", height: "0px"}),
                    d._validString(d.status.media.poster) && !d.status.nativeVideoControls && d.internal.poster.jq.show(), d.css.jq.videoPlay.length && d.css.jq.videoPlay.show(), d._error({type: b.jPlayer.error.URL, context: d.status.src, message: b.jPlayer.errorMsg.URL, hint: b.jPlayer.errorHint.URL})
            }, !1);
            b.each(b.jPlayer.htmlEvent, function (e, g) {
                a.addEventListener(this, function () {
                    c.gate && d._trigger(b.jPlayer.event[g])
                }, !1)
            })
        }, _getHtmlStatus: function (a, b) {
            var d = 0, e = 0, g = 0, f = 0;
            if (a.duration)this.status.duration = a.duration;
            d = a.currentTime;
            e = this.status.duration > 0 ? 100 * d / this.status.duration : 0;
            typeof a.seekable === "object" && a.seekable.length > 0 ? (g = this.status.duration > 0 ? 100 * a.seekable.end(a.seekable.length - 1) / this.status.duration : 100, f = 100 * a.currentTime / a.seekable.end(a.seekable.length - 1)) : (g = 100, f = e);
            b && (e = f = d = 0);
            this.status.seekPercent = g;
            this.status.currentPercentRelative = f;
            this.status.currentPercentAbsolute = e;
            this.status.currentTime = d;
            this.status.readyState = a.readyState;
            this.status.networkState = a.networkState;
            this.status.playbackRate =
                a.playbackRate;
            this.status.ended = a.ended
        }, _resetStatus: function () {
            this.status = b.extend({}, this.status, b.jPlayer.prototype.status)
        }, _trigger: function (a, c, d) {
            a = b.Event(a);
            a.jPlayer = {};
            a.jPlayer.version = b.extend({}, this.version);
            a.jPlayer.options = b.extend(!0, {}, this.options);
            a.jPlayer.status = b.extend(!0, {}, this.status);
            a.jPlayer.html = b.extend(!0, {}, this.html);
            a.jPlayer.flash = b.extend(!0, {}, this.flash);
            if (c)a.jPlayer.error = b.extend({}, c);
            if (d)a.jPlayer.warning = b.extend({}, d);
            this.element.trigger(a)
        },
        jPlayerFlashEvent: function (a, c) {
            if (a === b.jPlayer.event.ready)if (this.internal.ready) {
                if (this.flash.gate) {
                    if (this.status.srcSet) {
                        var d = this.status.currentTime, e = this.status.paused;
                        this.setMedia(this.status.media);
                        d > 0 && (e ? this.pause(d) : this.play(d))
                    }
                    this._trigger(b.jPlayer.event.flashreset)
                }
            } else this.internal.ready = !0, this.internal.flash.jq.css({width: "0px", height: "0px"}), this.version.flash = c.version, this.version.needFlash !== this.version.flash && this._error({type: b.jPlayer.error.VERSION, context: this.version.flash,
                message: b.jPlayer.errorMsg.VERSION + this.version.flash, hint: b.jPlayer.errorHint.VERSION}), this._trigger(b.jPlayer.event.repeat), this._trigger(a);
            if (this.flash.gate)switch (a) {
                case b.jPlayer.event.progress:
                    this._getFlashStatus(c);
                    this._updateInterface();
                    this._trigger(a);
                    break;
                case b.jPlayer.event.timeupdate:
                    this._getFlashStatus(c);
                    this._updateInterface();
                    this._trigger(a);
                    break;
                case b.jPlayer.event.play:
                    this._seeked();
                    this._updateButtons(!0);
                    this._trigger(a);
                    break;
                case b.jPlayer.event.pause:
                    this._updateButtons(!1);
                    this._trigger(a);
                    break;
                case b.jPlayer.event.ended:
                    this._updateButtons(!1);
                    this._trigger(a);
                    break;
                case b.jPlayer.event.click:
                    this._trigger(a);
                    break;
                case b.jPlayer.event.error:
                    this.status.waitForLoad = !0;
                    this.status.waitForPlay = !0;
                    this.status.video && this.internal.flash.jq.css({width: "0px", height: "0px"});
                    this._validString(this.status.media.poster) && this.internal.poster.jq.show();
                    this.css.jq.videoPlay.length && this.status.video && this.css.jq.videoPlay.show();
                    this.status.video ? this._flash_setVideo(this.status.media) :
                        this._flash_setAudio(this.status.media);
                    this._updateButtons(!1);
                    this._error({type: b.jPlayer.error.URL, context: c.src, message: b.jPlayer.errorMsg.URL, hint: b.jPlayer.errorHint.URL});
                    break;
                case b.jPlayer.event.seeking:
                    this._seeking();
                    this._trigger(a);
                    break;
                case b.jPlayer.event.seeked:
                    this._seeked();
                    this._trigger(a);
                    break;
                case b.jPlayer.event.ready:
                    break;
                default:
                    this._trigger(a)
            }
            return!1
        }, _getFlashStatus: function (a) {
            this.status.seekPercent = a.seekPercent;
            this.status.currentPercentRelative = a.currentPercentRelative;
            this.status.currentPercentAbsolute = a.currentPercentAbsolute;
            this.status.currentTime = a.currentTime;
            this.status.duration = a.duration;
            this.status.readyState = 4;
            this.status.networkState = 0;
            this.status.playbackRate = 1;
            this.status.ended = !1
        }, _updateButtons: function (a) {
            if (a !== f)this.status.paused = !a, this.css.jq.play.length && this.css.jq.pause.length && (a ? (this.css.jq.play.hide(), this.css.jq.pause.show()) : (this.css.jq.play.show(), this.css.jq.pause.hide()));
            this.css.jq.restoreScreen.length && this.css.jq.fullScreen.length &&
            (this.status.noFullScreen ? (this.css.jq.fullScreen.hide(), this.css.jq.restoreScreen.hide()) : this.options.fullScreen ? (this.css.jq.fullScreen.hide(), this.css.jq.restoreScreen.show()) : (this.css.jq.fullScreen.show(), this.css.jq.restoreScreen.hide()));
            this.css.jq.repeat.length && this.css.jq.repeatOff.length && (this.options.loop ? (this.css.jq.repeat.hide(), this.css.jq.repeatOff.show()) : (this.css.jq.repeat.show(), this.css.jq.repeatOff.hide()))
        }, _updateInterface: function () {
            this.css.jq.seekBar.length && this.css.jq.seekBar.width(this.status.seekPercent +
                "%");
            this.css.jq.playBar.length && this.css.jq.playBar.width(this.status.currentPercentRelative + "%");
            this.css.jq.currentTime.length && this.css.jq.currentTime.text(b.jPlayer.convertTime(this.status.currentTime));
            this.css.jq.duration.length && this.css.jq.duration.text(b.jPlayer.convertTime(this.status.duration))
        }, _seeking: function () {
            this.css.jq.seekBar.length && this.css.jq.seekBar.addClass("jp-seeking-bg")
        }, _seeked: function () {
            this.css.jq.seekBar.length && this.css.jq.seekBar.removeClass("jp-seeking-bg")
        },
        _resetGate: function () {
            this.html.audio.gate = !1;
            this.html.video.gate = !1;
            this.flash.gate = !1
        }, _resetActive: function () {
            this.html.active = !1;
            this.flash.active = !1
        }, setMedia: function (a) {
            var c = this, d = !1, e = this.status.media.poster !== a.poster;
            this._resetMedia();
            this._resetGate();
            this._resetActive();
            b.each(this.formats, function (e, f) {
                var i = c.format[f].media === "video";
                b.each(c.solutions, function (b, e) {
                    if (c[e].support[f] && c._validString(a[f])) {
                        var g = e === "html";
                        i ? (g ? (c.html.video.gate = !0, c._html_setVideo(a), c.html.active = !0) : (c.flash.gate = !0, c._flash_setVideo(a), c.flash.active = !0), c.css.jq.videoPlay.length && c.css.jq.videoPlay.show(), c.status.video = !0) : (g ? (c.html.audio.gate = !0, c._html_setAudio(a), c.html.active = !0) : (c.flash.gate = !0, c._flash_setAudio(a), c.flash.active = !0), c.css.jq.videoPlay.length && c.css.jq.videoPlay.hide(), c.status.video = !1);
                        d = !0;
                        return!1
                    }
                });
                if (d)return!1
            });
            if (d) {
                if ((!this.status.nativeVideoControls || !this.html.video.gate) && this._validString(a.poster))e ? this.htmlElement.poster.src = a.poster : this.internal.poster.jq.show();
                this.status.srcSet = !0;
                this.status.media = b.extend({}, a);
                this._updateButtons(!1);
                this._updateInterface()
            } else this._error({type: b.jPlayer.error.NO_SUPPORT, context: "{supplied:'" + this.options.supplied + "'}", message: b.jPlayer.errorMsg.NO_SUPPORT, hint: b.jPlayer.errorHint.NO_SUPPORT})
        }, _resetMedia: function () {
            this._resetStatus();
            this._updateButtons(!1);
            this._updateInterface();
            this._seeked();
            this.internal.poster.jq.hide();
            clearTimeout(this.internal.htmlDlyCmdId);
            this.html.active ? this._html_resetMedia() : this.flash.active &&
                this._flash_resetMedia()
        }, clearMedia: function () {
            this._resetMedia();
            this.html.active ? this._html_clearMedia() : this.flash.active && this._flash_clearMedia();
            this._resetGate();
            this._resetActive()
        }, load: function () {
            this.status.srcSet ? this.html.active ? this._html_load() : this.flash.active && this._flash_load() : this._urlNotSetError("load")
        }, play: function (a) {
            a = typeof a === "number" ? a : NaN;
            this.status.srcSet ? this.html.active ? this._html_play(a) : this.flash.active && this._flash_play(a) : this._urlNotSetError("play")
        }, videoPlay: function () {
            this.play()
        },
        pause: function (a) {
            a = typeof a === "number" ? a : NaN;
            this.status.srcSet ? this.html.active ? this._html_pause(a) : this.flash.active && this._flash_pause(a) : this._urlNotSetError("pause")
        }, pauseOthers: function () {
            var a = this;
            b.each(this.instances, function (b, d) {
                a.element !== d && d.data("jPlayer").status.srcSet && d.jPlayer("pause")
            })
        }, stop: function () {
            this.status.srcSet ? this.html.active ? this._html_pause(0) : this.flash.active && this._flash_pause(0) : this._urlNotSetError("stop")
        }, playHead: function (a) {
            a = this._limitValue(a, 0, 100);
            this.status.srcSet ? this.html.active ? this._html_playHead(a) : this.flash.active && this._flash_playHead(a) : this._urlNotSetError("playHead")
        }, _muted: function (a) {
            this.options.muted = a;
            this.html.used && this._html_mute(a);
            this.flash.used && this._flash_mute(a);
            !this.html.video.gate && !this.html.audio.gate && (this._updateMute(a), this._updateVolume(this.options.volume), this._trigger(b.jPlayer.event.volumechange))
        }, mute: function (a) {
            a = a === f ? !0 : !!a;
            this._muted(a)
        }, unmute: function (a) {
            a = a === f ? !0 : !!a;
            this._muted(!a)
        }, _updateMute: function (a) {
            if (a ===
                f)a = this.options.muted;
            this.css.jq.mute.length && this.css.jq.unmute.length && (this.status.noVolume ? (this.css.jq.mute.hide(), this.css.jq.unmute.hide()) : a ? (this.css.jq.mute.hide(), this.css.jq.unmute.show()) : (this.css.jq.mute.show(), this.css.jq.unmute.hide()))
        }, volume: function (a) {
            a = this._limitValue(a, 0, 1);
            this.options.volume = a;
            this.html.used && this._html_volume(a);
            this.flash.used && this._flash_volume(a);
            !this.html.video.gate && !this.html.audio.gate && (this._updateVolume(a), this._trigger(b.jPlayer.event.volumechange))
        },
        volumeBar: function (a) {
            if (this.css.jq.volumeBar.length) {
                var b = this.css.jq.volumeBar.offset(), d = a.pageX - b.left, e = this.css.jq.volumeBar.width(), a = this.css.jq.volumeBar.height() - a.pageY + b.top, b = this.css.jq.volumeBar.height();
                this.options.verticalVolume ? this.volume(a / b) : this.volume(d / e)
            }
            this.options.muted && this._muted(!1)
        }, volumeBarValue: function (a) {
            this.volumeBar(a)
        }, _updateVolume: function (a) {
            if (a === f)a = this.options.volume;
            a = this.options.muted ? 0 : a;
            this.status.noVolume ? (this.css.jq.volumeBar.length && this.css.jq.volumeBar.hide(),
                this.css.jq.volumeBarValue.length && this.css.jq.volumeBarValue.hide(), this.css.jq.volumeMax.length && this.css.jq.volumeMax.hide()) : (this.css.jq.volumeBar.length && this.css.jq.volumeBar.show(), this.css.jq.volumeBarValue.length && (this.css.jq.volumeBarValue.show(), this.css.jq.volumeBarValue[this.options.verticalVolume ? "height" : "width"](a * 100 + "%")), this.css.jq.volumeMax.length && this.css.jq.volumeMax.show())
        }, volumeMax: function () {
            this.volume(1);
            this.options.muted && this._muted(!1)
        }, _cssSelectorAncestor: function (a) {
            var c =
                this;
            this.options.cssSelectorAncestor = a;
            this._removeUiClass();
            this.ancestorJq = a ? b(a) : [];
            a && this.ancestorJq.length !== 1 && this._warning({type: b.jPlayer.warning.CSS_SELECTOR_COUNT, context: a, message: b.jPlayer.warningMsg.CSS_SELECTOR_COUNT + this.ancestorJq.length + " found for cssSelectorAncestor.", hint: b.jPlayer.warningHint.CSS_SELECTOR_COUNT});
            this._addUiClass();
            b.each(this.options.cssSelector, function (a, b) {
                c._cssSelector(a, b)
            })
        }, _cssSelector: function (a, c) {
            var d = this;
            typeof c === "string" ? b.jPlayer.prototype.options.cssSelector[a] ?
                (this.css.jq[a] && this.css.jq[a].length && this.css.jq[a].unbind(".jPlayer"), this.options.cssSelector[a] = c, this.css.cs[a] = this.options.cssSelectorAncestor + " " + c, this.css.jq[a] = c ? b(this.css.cs[a]) : [], this.css.jq[a].length && this.css.jq[a].bind("click.jPlayer", function (c) {
                    d[a](c);
                    b(this).blur();
                    return!1
                }), c && this.css.jq[a].length !== 1 && this._warning({type: b.jPlayer.warning.CSS_SELECTOR_COUNT, context: this.css.cs[a], message: b.jPlayer.warningMsg.CSS_SELECTOR_COUNT + this.css.jq[a].length + " found for " + a + " method.",
                    hint: b.jPlayer.warningHint.CSS_SELECTOR_COUNT})) : this._warning({type: b.jPlayer.warning.CSS_SELECTOR_METHOD, context: a, message: b.jPlayer.warningMsg.CSS_SELECTOR_METHOD, hint: b.jPlayer.warningHint.CSS_SELECTOR_METHOD}) : this._warning({type: b.jPlayer.warning.CSS_SELECTOR_STRING, context: c, message: b.jPlayer.warningMsg.CSS_SELECTOR_STRING, hint: b.jPlayer.warningHint.CSS_SELECTOR_STRING})
        }, seekBar: function (a) {
            if (this.css.jq.seekBar) {
                var b = this.css.jq.seekBar.offset(), a = a.pageX - b.left, b = this.css.jq.seekBar.width();
                this.playHead(100 * a / b)
            }
        }, playBar: function (a) {
            this.seekBar(a)
        }, repeat: function () {
            this._loop(!0)
        }, repeatOff: function () {
            this._loop(!1)
        }, _loop: function (a) {
            if (this.options.loop !== a)this.options.loop = a, this._updateButtons(), this._trigger(b.jPlayer.event.repeat)
        }, currentTime: function () {
        }, duration: function () {
        }, gui: function () {
        }, noSolution: function () {
        }, option: function (a, c) {
            var d = a;
            if (arguments.length === 0)return b.extend(!0, {}, this.options);
            if (typeof a === "string") {
                var e = a.split(".");
                if (c === f) {
                    for (var d = b.extend(!0,
                        {}, this.options), g = 0; g < e.length; g++)if (d[e[g]] !== f)d = d[e[g]]; else return this._warning({type: b.jPlayer.warning.OPTION_KEY, context: a, message: b.jPlayer.warningMsg.OPTION_KEY, hint: b.jPlayer.warningHint.OPTION_KEY}), f;
                    return d
                }
                for (var g = d = {}, h = 0; h < e.length; h++)h < e.length - 1 ? (g[e[h]] = {}, g = g[e[h]]) : g[e[h]] = c
            }
            this._setOptions(d);
            return this
        }, _setOptions: function (a) {
            var c = this;
            b.each(a, function (a, b) {
                c._setOption(a, b)
            });
            return this
        }, _setOption: function (a, c) {
            var d = this;
            switch (a) {
                case "volume":
                    this.volume(c);
                    break;
                case "muted":
                    this._muted(c);
                    break;
                case "cssSelectorAncestor":
                    this._cssSelectorAncestor(c);
                    break;
                case "cssSelector":
                    b.each(c, function (a, b) {
                        d._cssSelector(a, b)
                    });
                    break;
                case "fullScreen":
                    this.options[a] !== c && (this._removeUiClass(), this.options[a] = c, this._refreshSize());
                    break;
                case "size":
                    !this.options.fullScreen && this.options[a].cssClass !== c.cssClass && this._removeUiClass();
                    this.options[a] = b.extend({}, this.options[a], c);
                    this._refreshSize();
                    break;
                case "sizeFull":
                    this.options.fullScreen && this.options[a].cssClass !==
                        c.cssClass && this._removeUiClass();
                    this.options[a] = b.extend({}, this.options[a], c);
                    this._refreshSize();
                    break;
                case "autohide":
                    this.options[a] = b.extend({}, this.options[a], c);
                    this._updateAutohide();
                    break;
                case "loop":
                    this._loop(c);
                    break;
                case "nativeVideoControls":
                    this.options[a] = b.extend({}, this.options[a], c);
                    this.status.nativeVideoControls = this._uaBlocklist(this.options.nativeVideoControls);
                    this._restrictNativeVideoControls();
                    this._updateNativeVideoControls();
                    break;
                case "noFullScreen":
                    this.options[a] =
                        b.extend({}, this.options[a], c);
                    this.status.nativeVideoControls = this._uaBlocklist(this.options.nativeVideoControls);
                    this.status.noFullScreen = this._uaBlocklist(this.options.noFullScreen);
                    this._restrictNativeVideoControls();
                    this._updateButtons();
                    break;
                case "noVolume":
                    this.options[a] = b.extend({}, this.options[a], c);
                    this.status.noVolume = this._uaBlocklist(this.options.noVolume);
                    this._updateVolume();
                    this._updateMute();
                    break;
                case "emulateHtml":
                    this.options[a] !== c && ((this.options[a] = c) ? this._emulateHtmlBridge() :
                        this._destroyHtmlBridge())
            }
            return this
        }, _refreshSize: function () {
            this._setSize();
            this._addUiClass();
            this._updateSize();
            this._updateButtons();
            this._updateAutohide();
            this._trigger(b.jPlayer.event.resize)
        }, _setSize: function () {
            this.options.fullScreen ? (this.status.width = this.options.sizeFull.width, this.status.height = this.options.sizeFull.height, this.status.cssClass = this.options.sizeFull.cssClass) : (this.status.width = this.options.size.width, this.status.height = this.options.size.height, this.status.cssClass =
                this.options.size.cssClass);
            this.element.css({width: this.status.width, height: this.status.height})
        }, _addUiClass: function () {
            this.ancestorJq.length && this.ancestorJq.addClass(this.status.cssClass)
        }, _removeUiClass: function () {
            this.ancestorJq.length && this.ancestorJq.removeClass(this.status.cssClass)
        }, _updateSize: function () {
            this.internal.poster.jq.css({width: this.status.width, height: this.status.height});
            !this.status.waitForPlay && this.html.active && this.status.video || this.html.video.available && this.html.used &&
                this.status.nativeVideoControls ? this.internal.video.jq.css({width: this.status.width, height: this.status.height}) : !this.status.waitForPlay && this.flash.active && this.status.video && this.internal.flash.jq.css({width: this.status.width, height: this.status.height})
        }, _updateAutohide: function () {
            var a = this, b = function () {
                a.css.jq.gui.fadeIn(a.options.autohide.fadeIn, function () {
                    clearTimeout(a.internal.autohideId);
                    a.internal.autohideId = setTimeout(function () {
                        a.css.jq.gui.fadeOut(a.options.autohide.fadeOut)
                    }, a.options.autohide.hold)
                })
            };
            this.css.jq.gui.length && (this.css.jq.gui.stop(!0, !0), clearTimeout(this.internal.autohideId), this.element.unbind(".jPlayerAutohide"), this.css.jq.gui.unbind(".jPlayerAutohide"), this.status.nativeVideoControls ? this.css.jq.gui.hide() : this.options.fullScreen && this.options.autohide.full || !this.options.fullScreen && this.options.autohide.restored ? (this.element.bind("mousemove.jPlayer.jPlayerAutohide", b), this.css.jq.gui.bind("mousemove.jPlayer.jPlayerAutohide", b), this.css.jq.gui.hide()) : this.css.jq.gui.show())
        },
        fullScreen: function () {
            this._setOption("fullScreen", !0)
        }, restoreScreen: function () {
            this._setOption("fullScreen", !1)
        }, _html_initMedia: function () {
            this.htmlElement.media.src = this.status.src;
            this.options.preload !== "none" && this._html_load();
            this._trigger(b.jPlayer.event.timeupdate)
        }, _html_setAudio: function (a) {
            var c = this;
            b.each(this.formats, function (b, e) {
                if (c.html.support[e] && a[e])return c.status.src = a[e], c.status.format[e] = !0, c.status.formatType = e, !1
            });
            this.htmlElement.media = this.htmlElement.audio;
            this._html_initMedia()
        },
        _html_setVideo: function (a) {
            var c = this;
            b.each(this.formats, function (b, e) {
                if (c.html.support[e] && a[e])return c.status.src = a[e], c.status.format[e] = !0, c.status.formatType = e, !1
            });
            if (this.status.nativeVideoControls)this.htmlElement.video.poster = this._validString(a.poster) ? a.poster : "";
            this.htmlElement.media = this.htmlElement.video;
            this._html_initMedia()
        }, _html_resetMedia: function () {
            this.htmlElement.media && (this.htmlElement.media.id === this.internal.video.id && !this.status.nativeVideoControls && this.internal.video.jq.css({width: "0px",
                height: "0px"}), this.htmlElement.media.pause())
        }, _html_clearMedia: function () {
            if (this.htmlElement.media)this.htmlElement.media.src = "", this.htmlElement.media.load()
        }, _html_load: function () {
            if (this.status.waitForLoad)this.status.waitForLoad = !1, this.htmlElement.media.load();
            clearTimeout(this.internal.htmlDlyCmdId)
        }, _html_play: function (a) {
            var b = this;
            this._html_load();
            this.htmlElement.media.play();
            if (!isNaN(a))try {
                this.htmlElement.media.currentTime = a
            } catch (d) {
                this.internal.htmlDlyCmdId = setTimeout(function () {
                        b.play(a)
                    },
                    100);
                return
            }
            this._html_checkWaitForPlay()
        }, _html_pause: function (a) {
            var b = this;
            a > 0 ? this._html_load() : clearTimeout(this.internal.htmlDlyCmdId);
            this.htmlElement.media.pause();
            if (!isNaN(a))try {
                this.htmlElement.media.currentTime = a
            } catch (d) {
                this.internal.htmlDlyCmdId = setTimeout(function () {
                    b.pause(a)
                }, 100);
                return
            }
            a > 0 && this._html_checkWaitForPlay()
        }, _html_playHead: function (a) {
            var b = this;
            this._html_load();
            try {
                if (typeof this.htmlElement.media.seekable === "object" && this.htmlElement.media.seekable.length > 0)this.htmlElement.media.currentTime =
                    a * this.htmlElement.media.seekable.end(this.htmlElement.media.seekable.length - 1) / 100; else if (this.htmlElement.media.duration > 0 && !isNaN(this.htmlElement.media.duration))this.htmlElement.media.currentTime = a * this.htmlElement.media.duration / 100; else throw"e";
            } catch (d) {
                this.internal.htmlDlyCmdId = setTimeout(function () {
                    b.playHead(a)
                }, 100);
                return
            }
            this.status.waitForLoad || this._html_checkWaitForPlay()
        }, _html_checkWaitForPlay: function () {
            if (this.status.waitForPlay)this.status.waitForPlay = !1, this.css.jq.videoPlay.length &&
                this.css.jq.videoPlay.hide(), this.status.video && (this.internal.poster.jq.hide(), this.internal.video.jq.css({width: this.status.width, height: this.status.height}))
        }, _html_volume: function (a) {
            if (this.html.audio.available)this.htmlElement.audio.volume = a;
            if (this.html.video.available)this.htmlElement.video.volume = a
        }, _html_mute: function (a) {
            if (this.html.audio.available)this.htmlElement.audio.muted = a;
            if (this.html.video.available)this.htmlElement.video.muted = a
        }, _flash_setAudio: function (a) {
            var c = this;
            try {
                if (b.each(this.formats,
                    function (b, d) {
                        if (c.flash.support[d] && a[d]) {
                            switch (d) {
                                case "m4a":
                                case "fla":
                                    c._getMovie().fl_setAudio_m4a(a[d]);
                                    break;
                                case "mp3":
                                    c._getMovie().fl_setAudio_mp3(a[d])
                            }
                            c.status.src = a[d];
                            c.status.format[d] = !0;
                            c.status.formatType = d;
                            return!1
                        }
                    }), this.options.preload === "auto")this._flash_load(), this.status.waitForLoad = !1
            } catch (d) {
                this._flashError(d)
            }
        }, _flash_setVideo: function (a) {
            var c = this;
            try {
                if (b.each(this.formats, function (b, d) {
                    if (c.flash.support[d] && a[d]) {
                        switch (d) {
                            case "m4v":
                            case "flv":
                                c._getMovie().fl_setVideo_m4v(a[d])
                        }
                        c.status.src =
                            a[d];
                        c.status.format[d] = !0;
                        c.status.formatType = d;
                        return!1
                    }
                }), this.options.preload === "auto")this._flash_load(), this.status.waitForLoad = !1
            } catch (d) {
                this._flashError(d)
            }
        }, _flash_resetMedia: function () {
            this.internal.flash.jq.css({width: "0px", height: "0px"});
            this._flash_pause(NaN)
        }, _flash_clearMedia: function () {
            try {
                this._getMovie().fl_clearMedia()
            } catch (a) {
                this._flashError(a)
            }
        }, _flash_load: function () {
            try {
                this._getMovie().fl_load()
            } catch (a) {
                this._flashError(a)
            }
            this.status.waitForLoad = !1
        }, _flash_play: function (a) {
            try {
                this._getMovie().fl_play(a)
            } catch (b) {
                this._flashError(b)
            }
            this.status.waitForLoad = !1;
            this._flash_checkWaitForPlay()
        }, _flash_pause: function (a) {
            try {
                this._getMovie().fl_pause(a)
            } catch (b) {
                this._flashError(b)
            }
            if (a > 0)this.status.waitForLoad = !1, this._flash_checkWaitForPlay()
        }, _flash_playHead: function (a) {
            try {
                this._getMovie().fl_play_head(a)
            } catch (b) {
                this._flashError(b)
            }
            this.status.waitForLoad || this._flash_checkWaitForPlay()
        }, _flash_checkWaitForPlay: function () {
            if (this.status.waitForPlay)this.status.waitForPlay = !1, this.css.jq.videoPlay.length && this.css.jq.videoPlay.hide(), this.status.video &&
                (this.internal.poster.jq.hide(), this.internal.flash.jq.css({width: this.status.width, height: this.status.height}))
        }, _flash_volume: function (a) {
            try {
                this._getMovie().fl_volume(a)
            } catch (b) {
                this._flashError(b)
            }
        }, _flash_mute: function (a) {
            try {
                this._getMovie().fl_mute(a)
            } catch (b) {
                this._flashError(b)
            }
        }, _getMovie: function () {
            return document[this.internal.flash.id]
        }, _checkForFlash: function (a) {
            var b = !1, d;
            if (window.ActiveXObject)try {
                new ActiveXObject("ShockwaveFlash.ShockwaveFlash." + a), b = !0
            } catch (e) {
            } else navigator.plugins &&
                navigator.mimeTypes.length > 0 && (d = navigator.plugins["Shockwave Flash"]) && navigator.plugins["Shockwave Flash"].description.replace(/.*\s(\d+\.\d+).*/, "$1") >= a && (b = !0);
            return b
        }, _validString: function (a) {
            return a && typeof a === "string"
        }, _limitValue: function (a, b, d) {
            return a < b ? b : a > d ? d : a
        }, _urlNotSetError: function (a) {
            this._error({type: b.jPlayer.error.URL_NOT_SET, context: a, message: b.jPlayer.errorMsg.URL_NOT_SET, hint: b.jPlayer.errorHint.URL_NOT_SET})
        }, _flashError: function (a) {
            var c;
            c = this.internal.ready ? "FLASH_DISABLED" :
                "FLASH";
            this._error({type: b.jPlayer.error[c], context: this.internal.flash.swf, message: b.jPlayer.errorMsg[c] + a.message, hint: b.jPlayer.errorHint[c]});
            this.internal.flash.jq.css({width: "1px", height: "1px"})
        }, _error: function (a) {
            this._trigger(b.jPlayer.event.error, a);
            this.options.errorAlerts && this._alert("Error!" + (a.message ? "\n\n" + a.message : "") + (a.hint ? "\n\n" + a.hint : "") + "\n\nContext: " + a.context)
        }, _warning: function (a) {
            this._trigger(b.jPlayer.event.warning, f, a);
            this.options.warningAlerts && this._alert("Warning!" +
                (a.message ? "\n\n" + a.message : "") + (a.hint ? "\n\n" + a.hint : "") + "\n\nContext: " + a.context)
        }, _alert: function (a) {
            alert("jPlayer " + this.version.script + " : id='" + this.internal.self.id + "' : " + a)
        }, _emulateHtmlBridge: function () {
            var a = this;
            b.each(b.jPlayer.emulateMethods.split(/\s+/g), function (b, d) {
                a.internal.domNode[d] = function (b) {
                    a[d](b)
                }
            });
            b.each(b.jPlayer.event, function (c, d) {
                var e = !0;
                b.each(b.jPlayer.reservedEvent.split(/\s+/g), function (a, b) {
                    if (b === c)return e = !1
                });
                e && a.element.bind(d + ".jPlayer.jPlayerHtml",
                    function () {
                        a._emulateHtmlUpdate();
                        var b = document.createEvent("Event");
                        b.initEvent(c, !1, !0);
                        a.internal.domNode.dispatchEvent(b)
                    })
            })
        }, _emulateHtmlUpdate: function () {
            var a = this;
            b.each(b.jPlayer.emulateStatus.split(/\s+/g), function (b, d) {
                a.internal.domNode[d] = a.status[d]
            });
            b.each(b.jPlayer.emulateOptions.split(/\s+/g), function (b, d) {
                a.internal.domNode[d] = a.options[d]
            })
        }, _destroyHtmlBridge: function () {
            var a = this;
            this.element.unbind(".jPlayerHtml");
            b.each((b.jPlayer.emulateMethods + " " + b.jPlayer.emulateStatus +
                " " + b.jPlayer.emulateOptions).split(/\s+/g), function (b, d) {
                delete a.internal.domNode[d]
            })
        }};
    b.jPlayer.error = {FLASH: "e_flash", FLASH_DISABLED: "e_flash_disabled", NO_SOLUTION: "e_no_solution", NO_SUPPORT: "e_no_support", URL: "e_url", URL_NOT_SET: "e_url_not_set", VERSION: "e_version"};
    b.jPlayer.errorMsg = {FLASH: "jPlayer's Flash fallback is not configured correctly, or a command was issued before the jPlayer Ready event. Details: ", FLASH_DISABLED: "jPlayer's Flash fallback has been disabled by the browser due to the CSS rules you have used. Details: ",
        NO_SOLUTION: "No solution can be found by jPlayer in this browser. Neither HTML nor Flash can be used.", NO_SUPPORT: "It is not possible to play any media format provided in setMedia() on this browser using your current options.", URL: "Media URL could not be loaded.", URL_NOT_SET: "Attempt to issue media playback commands, while no media url is set.", VERSION: "jPlayer " + b.jPlayer.prototype.version.script + " needs jplayer.swf version " + b.jPlayer.prototype.version.needFlash + " but found "};
    b.jPlayer.errorHint =
    {FLASH: "Check your swfPath option and that jplayer.swf is there.", FLASH_DISABLED: "Check that you have not display:none; the jPlayer entity or any ancestor.", NO_SOLUTION: "Review the jPlayer options: support and supplied.", NO_SUPPORT: "Video or audio formats defined in the supplied option are missing.", URL: "Check media URL is valid.", URL_NOT_SET: "Use setMedia() to set the media URL.", VERSION: "Update jPlayer files."};
    b.jPlayer.warning = {CSS_SELECTOR_COUNT: "e_css_selector_count", CSS_SELECTOR_METHOD: "e_css_selector_method",
        CSS_SELECTOR_STRING: "e_css_selector_string", OPTION_KEY: "e_option_key"};
    b.jPlayer.warningMsg = {CSS_SELECTOR_COUNT: "The number of css selectors found did not equal one: ", CSS_SELECTOR_METHOD: "The methodName given in jPlayer('cssSelector') is not a valid jPlayer method.", CSS_SELECTOR_STRING: "The methodCssSelector given in jPlayer('cssSelector') is not a String or is empty.", OPTION_KEY: "The option requested in jPlayer('option') is undefined."};
    b.jPlayer.warningHint = {CSS_SELECTOR_COUNT: "Check your css selector and the ancestor.",
        CSS_SELECTOR_METHOD: "Check your method name.", CSS_SELECTOR_STRING: "Check your css selector is a string.", OPTION_KEY: "Check your option name."}
})(jQuery);


/**
 * Isotope v1.5.25
 * An exquisite jQuery plugin for magical layouts
 * http://isotope.metafizzy.co
 *
 * Commercial use requires one-time purchase of a commercial license
 * http://isotope.metafizzy.co/docs/license.html
 *
 * Non-commercial use is licensed under the MIT License
 *
 * Copyright 2013 Metafizzy
 */
(function (a, b, c) {
    "use strict";
    var d = a.document, e = a.Modernizr, f = function (a) {
        return a.charAt(0).toUpperCase() + a.slice(1)
    }, g = "Moz Webkit O Ms".split(" "), h = function (a) {
        var b = d.documentElement.style, c;
        if (typeof b[a] == "string")return a;
        a = f(a);
        for (var e = 0, h = g.length; e < h; e++) {
            c = g[e] + a;
            if (typeof b[c] == "string")return c
        }
    }, i = h("transform"), j = h("transitionProperty"), k = {csstransforms: function () {
        return!!i
    }, csstransforms3d: function () {
        var a = !!h("perspective");
        if (a) {
            var c = " -o- -moz- -ms- -webkit- -khtml- ".split(" "), d = "@media (" + c.join("transform-3d),(") + "modernizr)", e = b("<style>" + d + "{#modernizr{height:3px}}" + "</style>").appendTo("head"), f = b('<div id="modernizr" />').appendTo("html");
            a = f.height() === 3, f.remove(), e.remove()
        }
        return a
    }, csstransitions: function () {
        return!!j
    }}, l;
    if (e)for (l in k)e.hasOwnProperty(l) || e.addTest(l, k[l]); else {
        e = a.Modernizr = {_version: "1.6ish: miniModernizr for Isotope"};
        var m = " ", n;
        for (l in k)n = k[l](), e[l] = n, m += " " + (n ? "" : "no-") + l;
        b("html").addClass(m)
    }
    if (e.csstransforms) {
        var o = e.csstransforms3d ? {translate: function (a) {
            return"translate3d(" + a[0] + "px, " + a[1] + "px, 0) "
        }, scale: function (a) {
            return"scale3d(" + a + ", " + a + ", 1) "
        }} : {translate: function (a) {
            return"translate(" + a[0] + "px, " + a[1] + "px) "
        }, scale: function (a) {
            return"scale(" + a + ") "
        }}, p = function (a, c, d) {
            var e = b.data(a, "isoTransform") || {}, f = {}, g, h = {}, j;
            f[c] = d, b.extend(e, f);
            for (g in e)j = e[g], h[g] = o[g](j);
            var k = h.translate || "", l = h.scale || "", m = k + l;
            b.data(a, "isoTransform", e), a.style[i] = m
        };
        b.cssNumber.scale = !0, b.cssHooks.scale = {set: function (a, b) {
            p(a, "scale", b)
        }, get: function (a, c) {
            var d = b.data(a, "isoTransform");
            return d && d.scale ? d.scale : 1
        }}, b.fx.step.scale = function (a) {
            b.cssHooks.scale.set(a.elem, a.now + a.unit)
        }, b.cssNumber.translate = !0, b.cssHooks.translate = {set: function (a, b) {
            p(a, "translate", b)
        }, get: function (a, c) {
            var d = b.data(a, "isoTransform");
            return d && d.translate ? d.translate : [0, 0]
        }}
    }
    var q, r;
    e.csstransitions && (q = {WebkitTransitionProperty: "webkitTransitionEnd", MozTransitionProperty: "transitionend", OTransitionProperty: "oTransitionEnd otransitionend", transitionProperty: "transitionend"}[j], r = h("transitionDuration"));
    var s = b.event, t = b.event.handle ? "handle" : "dispatch", u;
    s.special.smartresize = {setup: function () {
        b(this).bind("resize", s.special.smartresize.handler)
    }, teardown: function () {
        b(this).unbind("resize", s.special.smartresize.handler)
    }, handler: function (a, b) {
        var c = this, d = arguments;
        a.type = "smartresize", u && clearTimeout(u), u = setTimeout(function () {
            s[t].apply(c, d)
        }, b === "execAsap" ? 0 : 100)
    }}, b.fn.smartresize = function (a) {
        return a ? this.bind("smartresize", a) : this.trigger("smartresize", ["execAsap"])
    }, b.Isotope = function (a, c, d) {
        this.element = b(c), this._create(a), this._init(d)
    };
    var v = ["width", "height"], w = b(a);
    b.Isotope.settings = {resizable: !0, layoutMode: "masonry", containerClass: "isotope", itemClass: "isotope-item", hiddenClass: "isotope-hidden", hiddenStyle: {opacity: 0, scale: .001}, visibleStyle: {opacity: 1, scale: 1}, containerStyle: {position: "relative", overflow: "hidden"}, animationEngine: "best-available", animationOptions: {queue: !1, duration: 800}, sortBy: "original-order", sortAscending: !0, resizesContainer: !0, transformsEnabled: !0, itemPositionDataEnabled: !1}, b.Isotope.prototype = {_create: function (a) {
        this.options = b.extend({}, b.Isotope.settings, a), this.styleQueue = [], this.elemCount = 0;
        var c = this.element[0].style;
        this.originalStyle = {};
        var d = v.slice(0);
        for (var e in this.options.containerStyle)d.push(e);
        for (var f = 0, g = d.length; f < g; f++)e = d[f], this.originalStyle[e] = c[e] || "";
        this.element.css(this.options.containerStyle), this._updateAnimationEngine(), this._updateUsingTransforms();
        var h = {"original-order": function (a, b) {
            return b.elemCount++, b.elemCount
        }, random: function () {
            return Math.random()
        }};
        this.options.getSortData = b.extend(this.options.getSortData, h), this.reloadItems(), this.offset = {left: parseInt(this.element.css("padding-left") || 0, 10), top: parseInt(this.element.css("padding-top") || 0, 10)};
        var i = this;
        setTimeout(function () {
            i.element.addClass(i.options.containerClass)
        }, 0), this.options.resizable && w.bind("smartresize.isotope", function () {
            i.resize()
        }), this.element.delegate("." + this.options.hiddenClass, "click", function () {
            return!1
        })
    }, _getAtoms: function (a) {
        var b = this.options.itemSelector, c = b ? a.filter(b).add(a.find(b)) : a, d = {position: "absolute"};
        return c = c.filter(function (a, b) {
            return b.nodeType === 1
        }), this.usingTransforms && (d.left = 0, d.top = 0), c.css(d).addClass(this.options.itemClass), this.updateSortData(c, !0), c
    }, _init: function (a) {
        this.$filteredAtoms = this._filter(this.$allAtoms), this._sort(), this.reLayout(a)
    }, option: function (a) {
        if (b.isPlainObject(a)) {
            this.options = b.extend(!0, this.options, a);
            var c;
            for (var d in a)c = "_update" + f(d), this[c] && this[c]()
        }
    }, _updateAnimationEngine: function () {
        var a = this.options.animationEngine.toLowerCase().replace(/[ _\-]/g, ""), b;
        switch (a) {
            case"css":
            case"none":
                b = !1;
                break;
            case"jquery":
                b = !0;
                break;
            default:
                b = !e.csstransitions
        }
        this.isUsingJQueryAnimation = b, this._updateUsingTransforms()
    }, _updateTransformsEnabled: function () {
        this._updateUsingTransforms()
    }, _updateUsingTransforms: function () {
        var a = this.usingTransforms = this.options.transformsEnabled && e.csstransforms && e.csstransitions && !this.isUsingJQueryAnimation;
        a || (delete this.options.hiddenStyle.scale, delete this.options.visibleStyle.scale), this.getPositionStyles = a ? this._translate : this._positionAbs
    }, _filter: function (a) {
        var b = this.options.filter === "" ? "*" : this.options.filter;
        if (!b)return a;
        var c = this.options.hiddenClass, d = "." + c, e = a.filter(d), f = e;
        if (b !== "*") {
            f = e.filter(b);
            var g = a.not(d).not(b).addClass(c);
            this.styleQueue.push({$el: g, style: this.options.hiddenStyle})
        }
        return this.styleQueue.push({$el: f, style: this.options.visibleStyle}), f.removeClass(c), a.filter(b)
    }, updateSortData: function (a, c) {
        var d = this, e = this.options.getSortData, f, g;
        a.each(function () {
            f = b(this), g = {};
            for (var a in e)!c && a === "original-order" ? g[a] = b.data(this, "isotope-sort-data")[a] : g[a] = e[a](f, d);
            b.data(this, "isotope-sort-data", g)
        })
    }, _sort: function () {
        var a = this.options.sortBy, b = this._getSorter, c = this.options.sortAscending ? 1 : -1, d = function (d, e) {
            var f = b(d, a), g = b(e, a);
            return f === g && a !== "original-order" && (f = b(d, "original-order"), g = b(e, "original-order")), (f > g ? 1 : f < g ? -1 : 0) * c
        };
        this.$filteredAtoms.sort(d)
    }, _getSorter: function (a, c) {
        return b.data(a, "isotope-sort-data")[c]
    }, _translate: function (a, b) {
        return{translate: [a, b]}
    }, _positionAbs: function (a, b) {
        return{left: a, top: b}
    }, _pushPosition: function (a, b, c) {
        b = Math.round(b + this.offset.left), c = Math.round(c + this.offset.top);
        var d = this.getPositionStyles(b, c);
        this.styleQueue.push({$el: a, style: d}), this.options.itemPositionDataEnabled && a.data("isotope-item-position", {x: b, y: c})
    }, layout: function (a, b) {
        var c = this.options.layoutMode;
        this["_" + c + "Layout"](a);
        if (this.options.resizesContainer) {
            var d = this["_" + c + "GetContainerSize"]();
            this.styleQueue.push({$el: this.element, style: d})
        }
        this._processStyleQueue(a, b), this.isLaidOut = !0
    }, _processStyleQueue: function (a, c) {
        var d = this.isLaidOut ? this.isUsingJQueryAnimation ? "animate" : "css" : "css", f = this.options.animationOptions, g = this.options.onLayout, h, i, j, k;
        i = function (a, b) {
            b.$el[d](b.style, f)
        };
        if (this._isInserting && this.isUsingJQueryAnimation)i = function (a, b) {
            h = b.$el.hasClass("no-transition") ? "css" : d, b.$el[h](b.style, f)
        }; else if (c || g || f.complete) {
            var l = !1, m = [c, g, f.complete], n = this;
            j = !0, k = function () {
                if (l)return;
                var b;
                for (var c = 0, d = m.length; c < d; c++)b = m[c], typeof b == "function" && b.call(n.element, a, n);
                l = !0
            };
            if (this.isUsingJQueryAnimation && d === "animate")f.complete = k, j = !1; else if (e.csstransitions) {
                var o = 0, p = this.styleQueue[0], s = p && p.$el, t;
                while (!s || !s.length) {
                    t = this.styleQueue[o++];
                    if (!t)return;
                    s = t.$el
                }
                var u = parseFloat(getComputedStyle(s[0])[r]);
                u > 0 && (i = function (a, b) {
                    b.$el[d](b.style, f).one(q, k)
                }, j = !1)
            }
        }
        b.each(this.styleQueue, i), j && k(), this.styleQueue = []
    }, resize: function () {
        this["_" + this.options.layoutMode + "ResizeChanged"]() && this.reLayout()
    }, reLayout: function (a) {
        this["_" + this.options.layoutMode + "Reset"](), this.layout(this.$filteredAtoms, a)
    }, addItems: function (a, b) {
        var c = this._getAtoms(a);
        this.$allAtoms = this.$allAtoms.add(c), b && b(c)
    }, insert: function (a, b) {
        this.element.append(a);
        var c = this;
        this.addItems(a, function (a) {
            var d = c._filter(a);
            c._addHideAppended(d), c._sort(), c.reLayout(), c._revealAppended(d, b)
        })
    }, appended: function (a, b) {
        var c = this;
        this.addItems(a, function (a) {
            c._addHideAppended(a), c.layout(a), c._revealAppended(a, b)
        })
    }, _addHideAppended: function (a) {
        this.$filteredAtoms = this.$filteredAtoms.add(a), a.addClass("no-transition"), this._isInserting = !0, this.styleQueue.push({$el: a, style: this.options.hiddenStyle})
    }, _revealAppended: function (a, b) {
        var c = this;
        setTimeout(function () {
            a.removeClass("no-transition"), c.styleQueue.push({$el: a, style: c.options.visibleStyle}), c._isInserting = !1, c._processStyleQueue(a, b)
        }, 10)
    }, reloadItems: function () {
        this.$allAtoms = this._getAtoms(this.element.children())
    }, remove: function (a, b) {
        this.$allAtoms = this.$allAtoms.not(a), this.$filteredAtoms = this.$filteredAtoms.not(a);
        var c = this, d = function () {
            a.remove(), b && b.call(c.element)
        };
        a.filter(":not(." + this.options.hiddenClass + ")").length ? (this.styleQueue.push({$el: a, style: this.options.hiddenStyle}), this._sort(), this.reLayout(d)) : d()
    }, shuffle: function (a) {
        this.updateSortData(this.$allAtoms), this.options.sortBy = "random", this._sort(), this.reLayout(a)
    }, destroy: function () {
        var a = this.usingTransforms, b = this.options;
        this.$allAtoms.removeClass(b.hiddenClass + " " + b.itemClass).each(function () {
            var b = this.style;
            b.position = "", b.top = "", b.left = "", b.opacity = "", a && (b[i] = "")
        });
        var c = this.element[0].style;
        for (var d in this.originalStyle)c[d] = this.originalStyle[d];
        this.element.unbind(".isotope").undelegate("." + b.hiddenClass, "click").removeClass(b.containerClass).removeData("isotope"), w.unbind(".isotope")
    }, _getSegments: function (a) {
        var b = this.options.layoutMode, c = a ? "rowHeight" : "columnWidth", d = a ? "height" : "width", e = a ? "rows" : "cols", g = this.element[d](), h, i = this.options[b] && this.options[b][c] || this.$filteredAtoms["outer" + f(d)](!0) || g;
        h = Math.floor(g / i), h = Math.max(h, 1), this[b][e] = h, this[b][c] = i
    }, _checkIfSegmentsChanged: function (a) {
        var b = this.options.layoutMode, c = a ? "rows" : "cols", d = this[b][c];
        return this._getSegments(a), this[b][c] !== d
    }, _masonryReset: function () {
        this.masonry = {}, this._getSegments();
        var a = this.masonry.cols;
        this.masonry.colYs = [];
        while (a--)this.masonry.colYs.push(0)
    }, _masonryLayout: function (a) {
        var c = this, d = c.masonry;
        a.each(function () {
            var a = b(this), e = Math.ceil(a.outerWidth(!0) / d.columnWidth);
            e = Math.min(e, d.cols);
            if (e === 1)c._masonryPlaceBrick(a, d.colYs); else {
                var f = d.cols + 1 - e, g = [], h, i;
                for (i = 0; i < f; i++)h = d.colYs.slice(i, i + e), g[i] = Math.max.apply(Math, h);
                c._masonryPlaceBrick(a, g)
            }
        })
    }, _masonryPlaceBrick: function (a, b) {
        var c = Math.min.apply(Math, b), d = 0;
        for (var e = 0, f = b.length; e < f; e++)if (b[e] === c) {
            d = e;
            break
        }
        var g = this.masonry.columnWidth * d, h = c;
        this._pushPosition(a, g, h);
        var i = c + a.outerHeight(!0), j = this.masonry.cols + 1 - f;
        for (e = 0; e < j; e++)this.masonry.colYs[d + e] = i
    }, _masonryGetContainerSize: function () {
        var a = Math.max.apply(Math, this.masonry.colYs);
        return{height: a}
    }, _masonryResizeChanged: function () {
        return this._checkIfSegmentsChanged()
    }, _fitRowsReset: function () {
        this.fitRows = {x: 0, y: 0, height: 0}
    }, _fitRowsLayout: function (a) {
        var c = this, d = this.element.width(), e = this.fitRows;
        a.each(function () {
            var a = b(this), f = a.outerWidth(!0), g = a.outerHeight(!0);
            e.x !== 0 && f + e.x > d && (e.x = 0, e.y = e.height), c._pushPosition(a, e.x, e.y), e.height = Math.max(e.y + g, e.height), e.x += f
        })
    }, _fitRowsGetContainerSize: function () {
        return{height: this.fitRows.height}
    }, _fitRowsResizeChanged: function () {
        return!0
    }, _cellsByRowReset: function () {
        this.cellsByRow = {index: 0}, this._getSegments(), this._getSegments(!0)
    }, _cellsByRowLayout: function (a) {
        var c = this, d = this.cellsByRow;
        a.each(function () {
            var a = b(this), e = d.index % d.cols, f = Math.floor(d.index / d.cols), g = (e + .5) * d.columnWidth - a.outerWidth(!0) / 2, h = (f + .5) * d.rowHeight - a.outerHeight(!0) / 2;
            c._pushPosition(a, g, h), d.index++
        })
    }, _cellsByRowGetContainerSize: function () {
        return{height: Math.ceil(this.$filteredAtoms.length / this.cellsByRow.cols) * this.cellsByRow.rowHeight + this.offset.top}
    }, _cellsByRowResizeChanged: function () {
        return this._checkIfSegmentsChanged()
    }, _straightDownReset: function () {
        this.straightDown = {y: 0}
    }, _straightDownLayout: function (a) {
        var c = this;
        a.each(function (a) {
            var d = b(this);
            c._pushPosition(d, 0, c.straightDown.y), c.straightDown.y += d.outerHeight(!0)
        })
    }, _straightDownGetContainerSize: function () {
        return{height: this.straightDown.y}
    }, _straightDownResizeChanged: function () {
        return!0
    }, _masonryHorizontalReset: function () {
        this.masonryHorizontal = {}, this._getSegments(!0);
        var a = this.masonryHorizontal.rows;
        this.masonryHorizontal.rowXs = [];
        while (a--)this.masonryHorizontal.rowXs.push(0)
    }, _masonryHorizontalLayout: function (a) {
        var c = this, d = c.masonryHorizontal;
        a.each(function () {
            var a = b(this), e = Math.ceil(a.outerHeight(!0) / d.rowHeight);
            e = Math.min(e, d.rows);
            if (e === 1)c._masonryHorizontalPlaceBrick(a, d.rowXs); else {
                var f = d.rows + 1 - e, g = [], h, i;
                for (i = 0; i < f; i++)h = d.rowXs.slice(i, i + e), g[i] = Math.max.apply(Math, h);
                c._masonryHorizontalPlaceBrick(a, g)
            }
        })
    }, _masonryHorizontalPlaceBrick: function (a, b) {
        var c = Math.min.apply(Math, b), d = 0;
        for (var e = 0, f = b.length; e < f; e++)if (b[e] === c) {
            d = e;
            break
        }
        var g = c, h = this.masonryHorizontal.rowHeight * d;
        this._pushPosition(a, g, h);
        var i = c + a.outerWidth(!0), j = this.masonryHorizontal.rows + 1 - f;
        for (e = 0; e < j; e++)this.masonryHorizontal.rowXs[d + e] = i
    }, _masonryHorizontalGetContainerSize: function () {
        var a = Math.max.apply(Math, this.masonryHorizontal.rowXs);
        return{width: a}
    }, _masonryHorizontalResizeChanged: function () {
        return this._checkIfSegmentsChanged(!0)
    }, _fitColumnsReset: function () {
        this.fitColumns = {x: 0, y: 0, width: 0}
    }, _fitColumnsLayout: function (a) {
        var c = this, d = this.element.height(), e = this.fitColumns;
        a.each(function () {
            var a = b(this), f = a.outerWidth(!0), g = a.outerHeight(!0);
            e.y !== 0 && g + e.y > d && (e.x = e.width, e.y = 0), c._pushPosition(a, e.x, e.y), e.width = Math.max(e.x + f, e.width), e.y += g
        })
    }, _fitColumnsGetContainerSize: function () {
        return{width: this.fitColumns.width}
    }, _fitColumnsResizeChanged: function () {
        return!0
    }, _cellsByColumnReset: function () {
        this.cellsByColumn = {index: 0}, this._getSegments(), this._getSegments(!0)
    }, _cellsByColumnLayout: function (a) {
        var c = this, d = this.cellsByColumn;
        a.each(function () {
            var a = b(this), e = Math.floor(d.index / d.rows), f = d.index % d.rows, g = (e + .5) * d.columnWidth - a.outerWidth(!0) / 2, h = (f + .5) * d.rowHeight - a.outerHeight(!0) / 2;
            c._pushPosition(a, g, h), d.index++
        })
    }, _cellsByColumnGetContainerSize: function () {
        return{width: Math.ceil(this.$filteredAtoms.length / this.cellsByColumn.rows) * this.cellsByColumn.columnWidth}
    }, _cellsByColumnResizeChanged: function () {
        return this._checkIfSegmentsChanged(!0)
    }, _straightAcrossReset: function () {
        this.straightAcross = {x: 0}
    }, _straightAcrossLayout: function (a) {
        var c = this;
        a.each(function (a) {
            var d = b(this);
            c._pushPosition(d, c.straightAcross.x, 0), c.straightAcross.x += d.outerWidth(!0)
        })
    }, _straightAcrossGetContainerSize: function () {
        return{width: this.straightAcross.x}
    }, _straightAcrossResizeChanged: function () {
        return!0
    }}, b.fn.imagesLoaded = function (a) {
        function h() {
            a.call(c, d)
        }

        function i(a) {
            var c = a.target;
            c.src !== f && b.inArray(c, g) === -1 && (g.push(c), --e <= 0 && (setTimeout(h), d.unbind(".imagesLoaded", i)))
        }

        var c = this, d = c.find("img").add(c.filter("img")), e = d.length, f = "", g = [];
        return e || h(), d.bind("load.imagesLoaded error.imagesLoaded", i).each(function () {
            var a = this.src;
            this.src = f, this.src = a
        }), c
    };
    var x = function (b) {
        a.console && a.console.error(b)
    };
    b.fn.isotope = function (a, c) {
        if (typeof a == "string") {
            var d = Array.prototype.slice.call(arguments, 1);
            this.each(function () {
                var c = b.data(this, "isotope");
                if (!c) {
                    x("cannot call methods on isotope prior to initialization; attempted to call method '" + a + "'");
                    return
                }
                if (!b.isFunction(c[a]) || a.charAt(0) === "_") {
                    x("no such method '" + a + "' for isotope instance");
                    return
                }
                c[a].apply(c, d)
            })
        } else this.each(function () {
            var d = b.data(this, "isotope");
            d ? (d.option(a), d._init(c)) : b.data(this, "isotope", new b.Isotope(a, this, c))
        });
        return this
    }
})(window, jQuery);


/* Modernizr 2.5.3 (Custom Build) | MIT & BSD
 * Build: http://www.modernizr.com/download#-cssanimations-csstransitions-shiv-cssclasses-testprop-testallprops-domprefixes-load
 */
;
window.Modernizr = function (a, b, c) {
    function x(a) {
        j.cssText = a
    }

    function y(a, b) {
        return x(prefixes.join(a + ";") + (b || ""))
    }

    function z(a, b) {
        return typeof a === b
    }

    function A(a, b) {
        return!!~("" + a).indexOf(b)
    }

    function B(a, b) {
        for (var d in a)if (j[a[d]] !== c)return b == "pfx" ? a[d] : !0;
        return!1
    }

    function C(a, b, d) {
        for (var e in a) {
            var f = b[a[e]];
            if (f !== c)return d === !1 ? a[e] : z(f, "function") ? f.bind(d || b) : f
        }
        return!1
    }

    function D(a, b, c) {
        var d = a.charAt(0).toUpperCase() + a.substr(1), e = (a + " " + n.join(d + " ") + d).split(" ");
        return z(b, "string") || z(b, "undefined") ? B(e, b) : (e = (a + " " + o.join(d + " ") + d).split(" "), C(e, b, c))
    }

    var d = "2.5.3", e = {}, f = !0, g = b.documentElement, h = "modernizr", i = b.createElement(h), j = i.style, k, l = {}.toString, m = "Webkit Moz O ms", n = m.split(" "), o = m.toLowerCase().split(" "), p = {}, q = {}, r = {}, s = [], t = s.slice, u, v = {}.hasOwnProperty, w;
    !z(v, "undefined") && !z(v.call, "undefined") ? w = function (a, b) {
        return v.call(a, b)
    } : w = function (a, b) {
        return b in a && z(a.constructor.prototype[b], "undefined")
    }, Function.prototype.bind || (Function.prototype.bind = function (b) {
        var c = this;
        if (typeof c != "function")throw new TypeError;
        var d = t.call(arguments, 1), e = function () {
            if (this instanceof e) {
                var a = function () {
                };
                a.prototype = c.prototype;
                var f = new a, g = c.apply(f, d.concat(t.call(arguments)));
                return Object(g) === g ? g : f
            }
            return c.apply(b, d.concat(t.call(arguments)))
        };
        return e
    }), p.cssanimations = function () {
        return D("animationName")
    }, p.csstransitions = function () {
        return D("transition")
    };
    for (var E in p)w(p, E) && (u = E.toLowerCase(), e[u] = p[E](), s.push((e[u] ? "" : "no-") + u));
    return x(""), i = k = null, function (a, b) {
        function g(a, b) {
            var c = a.createElement("p"), d = a.getElementsByTagName("head")[0] || a.documentElement;
            return c.innerHTML = "x<style>" + b + "</style>", d.insertBefore(c.lastChild, d.firstChild)
        }

        function h() {
            var a = k.elements;
            return typeof a == "string" ? a.split(" ") : a
        }

        function i(a) {
            var b = {}, c = a.createElement, e = a.createDocumentFragment, f = e();
            a.createElement = function (a) {
                var e = (b[a] || (b[a] = c(a))).cloneNode();
                return k.shivMethods && e.canHaveChildren && !d.test(a) ? f.appendChild(e) : e
            }, a.createDocumentFragment = Function("h,f", "return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&(" + h().join().replace(/\w+/g, function (a) {
                return b[a] = c(a), f.createElement(a), 'c("' + a + '")'
            }) + ");return n}")(k, f)
        }

        function j(a) {
            var b;
            return a.documentShived ? a : (k.shivCSS && !e && (b = !!g(a, "article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio{display:none}canvas,video{display:inline-block;*display:inline;*zoom:1}[hidden]{display:none}audio[controls]{display:inline-block;*display:inline;*zoom:1}mark{background:#FF0;color:#000}")), f || (b = !i(a)), b && (a.documentShived = b), a)
        }

        var c = a.html5 || {}, d = /^<|^(?:button|form|map|select|textarea)$/i, e, f;
        (function () {
            var a = b.createElement("a");
            a.innerHTML = "<xyz></xyz>", e = "hidden"in a, f = a.childNodes.length == 1 || function () {
                try {
                    b.createElement("a")
                } catch (a) {
                    return!0
                }
                var c = b.createDocumentFragment();
                return typeof c.cloneNode == "undefined" || typeof c.createDocumentFragment == "undefined" || typeof c.createElement == "undefined"
            }()
        })();
        var k = {elements: c.elements || "abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video", shivCSS: c.shivCSS !== !1, shivMethods: c.shivMethods !== !1, type: "default", shivDocument: j};
        a.html5 = k, j(b)
    }(this, b), e._version = d, e._domPrefixes = o, e._cssomPrefixes = n, e.testProp = function (a) {
        return B([a])
    }, e.testAllProps = D, g.className = g.className.replace(/(^|\s)no-js(\s|$)/, "$1$2") + (f ? " js " + s.join(" ") : ""), e
}(this, this.document), function (a, b, c) {
    function d(a) {
        return o.call(a) == "[object Function]"
    }

    function e(a) {
        return typeof a == "string"
    }

    function f() {
    }

    function g(a) {
        return!a || a == "loaded" || a == "complete" || a == "uninitialized"
    }

    function h() {
        var a = p.shift();
        q = 1, a ? a.t ? m(function () {
            (a.t == "c" ? B.injectCss : B.injectJs)(a.s, 0, a.a, a.x, a.e, 1)
        }, 0) : (a(), h()) : q = 0
    }

    function i(a, c, d, e, f, i, j) {
        function k(b) {
            if (!o && g(l.readyState) && (u.r = o = 1, !q && h(), l.onload = l.onreadystatechange = null, b)) {
                a != "img" && m(function () {
                    t.removeChild(l)
                }, 50);
                for (var d in y[c])y[c].hasOwnProperty(d) && y[c][d].onload()
            }
        }

        var j = j || B.errorTimeout, l = {}, o = 0, r = 0, u = {t: d, s: c, e: f, a: i, x: j};
        y[c] === 1 && (r = 1, y[c] = [], l = b.createElement(a)), a == "object" ? l.data = c : (l.src = c, l.type = a), l.width = l.height = "0", l.onerror = l.onload = l.onreadystatechange = function () {
            k.call(this, r)
        }, p.splice(e, 0, u), a != "img" && (r || y[c] === 2 ? (t.insertBefore(l, s ? null : n), m(k, j)) : y[c].push(l))
    }

    function j(a, b, c, d, f) {
        return q = 0, b = b || "j", e(a) ? i(b == "c" ? v : u, a, b, this.i++, c, d, f) : (p.splice(this.i++, 0, a), p.length == 1 && h()), this
    }

    function k() {
        var a = B;
        return a.loader = {load: j, i: 0}, a
    }

    var l = b.documentElement, m = a.setTimeout, n = b.getElementsByTagName("script")[0], o = {}.toString, p = [], q = 0, r = "MozAppearance"in l.style, s = r && !!b.createRange().compareNode, t = s ? l : n.parentNode, l = a.opera && o.call(a.opera) == "[object Opera]", l = !!b.attachEvent && !l, u = r ? "object" : l ? "script" : "img", v = l ? "script" : u, w = Array.isArray || function (a) {
        return o.call(a) == "[object Array]"
    }, x = [], y = {}, z = {timeout: function (a, b) {
        return b.length && (a.timeout = b[0]), a
    }}, A, B;
    B = function (a) {
        function b(a) {
            var a = a.split("!"), b = x.length, c = a.pop(), d = a.length, c = {url: c, origUrl: c, prefixes: a}, e, f, g;
            for (f = 0; f < d; f++)g = a[f].split("="), (e = z[g.shift()]) && (c = e(c, g));
            for (f = 0; f < b; f++)c = x[f](c);
            return c
        }

        function g(a, e, f, g, i) {
            var j = b(a), l = j.autoCallback;
            j.url.split(".").pop().split("?").shift(), j.bypass || (e && (e = d(e) ? e : e[a] || e[g] || e[a.split("/").pop().split("?")[0]] || h), j.instead ? j.instead(a, e, f, g, i) : (y[j.url] ? j.noexec = !0 : y[j.url] = 1, f.load(j.url, j.forceCSS || !j.forceJS && "css" == j.url.split(".").pop().split("?").shift() ? "c" : c, j.noexec, j.attrs, j.timeout), (d(e) || d(l)) && f.load(function () {
                k(), e && e(j.origUrl, i, g), l && l(j.origUrl, i, g), y[j.url] = 2
            })))
        }

        function i(a, b) {
            function c(a, c) {
                if (a) {
                    if (e(a))c || (j = function () {
                        var a = [].slice.call(arguments);
                        k.apply(this, a), l()
                    }), g(a, j, b, 0, h); else if (Object(a) === a)for (n in m = function () {
                        var b = 0, c;
                        for (c in a)a.hasOwnProperty(c) && b++;
                        return b
                    }(), a)a.hasOwnProperty(n) && (!c && !--m && (d(j) ? j = function () {
                        var a = [].slice.call(arguments);
                        k.apply(this, a), l()
                    } : j[n] = function (a) {
                        return function () {
                            var b = [].slice.call(arguments);
                            a && a.apply(this, b), l()
                        }
                    }(k[n])), g(a[n], j, b, n, h))
                } else!c && l()
            }

            var h = !!a.test, i = a.load || a.both, j = a.callback || f, k = j, l = a.complete || f, m, n;
            c(h ? a.yep : a.nope, !!i), i && c(i)
        }

        var j, l, m = this.yepnope.loader;
        if (e(a))g(a, 0, m, 0); else if (w(a))for (j = 0; j < a.length; j++)l = a[j], e(l) ? g(l, 0, m, 0) : w(l) ? B(l) : Object(l) === l && i(l, m); else Object(a) === a && i(a, m)
    }, B.addPrefix = function (a, b) {
        z[a] = b
    }, B.addFilter = function (a) {
        x.push(a)
    }, B.errorTimeout = 1e4, b.readyState == null && b.addEventListener && (b.readyState = "loading", b.addEventListener("DOMContentLoaded", A = function () {
        b.removeEventListener("DOMContentLoaded", A, 0), b.readyState = "complete"
    }, 0)), a.yepnope = k(), a.yepnope.executeStack = h, a.yepnope.injectJs = function (a, c, d, e, i, j) {
        var k = b.createElement("script"), l, o, e = e || B.errorTimeout;
        k.src = a;
        for (o in d)k.setAttribute(o, d[o]);
        c = j ? h : c || f, k.onreadystatechange = k.onload = function () {
            !l && g(k.readyState) && (l = 1, c(), k.onload = k.onreadystatechange = null)
        }, m(function () {
            l || (l = 1, c(1))
        }, e), i ? k.onload() : n.parentNode.insertBefore(k, n)
    }, a.yepnope.injectCss = function (a, c, d, e, g, i) {
        var e = b.createElement("link"), j, c = i ? h : c || f;
        e.href = a, e.rel = "stylesheet", e.type = "text/css";
        for (j in d)e.setAttribute(j, d[j]);
        g || (n.parentNode.insertBefore(e, n), m(c, 0))
    }
}(this, document), Modernizr.load = function () {
    yepnope.apply(window, [].slice.call(arguments, 0))
};


/*
 * jQuery FlexSlider v2.1
 * http://www.woothemes.com/flexslider/
 *
 * Copyright 2012 WooThemes
 * Free to use under the GPLv2 license.
 * http://www.gnu.org/licenses/gpl-2.0.html
 *
 * Contributing author: Tyler Smith (@mbmufffin)
 */
(function (d) {
    d.flexslider = function (j, l) {
        var a = d(j), c = d.extend({}, d.flexslider.defaults, l), e = c.namespace, q = "ontouchstart"in window || window.DocumentTouch && document instanceof DocumentTouch, u = q ? "touchend" : "click", m = "vertical" === c.direction, n = c.reverse, h = 0 < c.itemWidth, s = "fade" === c.animation, t = "" !== c.asNavFor, f = {};
        d.data(j, "flexslider", a);
        f = {init: function () {
            a.animating = !1;
            a.currentSlide = c.startAt;
            a.animatingTo = a.currentSlide;
            a.atEnd = 0 === a.currentSlide || a.currentSlide === a.last;
            a.containerSelector = c.selector.substr(0,
                c.selector.search(" "));
            a.slides = d(c.selector, a);
            a.container = d(a.containerSelector, a);
            a.count = a.slides.length;
            a.syncExists = 0 < d(c.sync).length;
            "slide" === c.animation && (c.animation = "swing");
            a.prop = m ? "top" : "marginLeft";
            a.args = {};
            a.manualPause = !1;
            var b = a, g;
            if (g = !c.video)if (g = !s)if (g = c.useCSS)a:{
                g = document.createElement("div");
                var p = ["perspectiveProperty", "WebkitPerspective", "MozPerspective", "OPerspective", "msPerspective"], e;
                for (e in p)if (void 0 !== g.style[p[e]]) {
                    a.pfx = p[e].replace("Perspective", "").toLowerCase();
                    a.prop = "-" + a.pfx + "-transform";
                    g = !0;
                    break a
                }
                g = !1
            }
            b.transitions = g;
            "" !== c.controlsContainer && (a.controlsContainer = 0 < d(c.controlsContainer).length && d(c.controlsContainer));
            "" !== c.manualControls && (a.manualControls = 0 < d(c.manualControls).length && d(c.manualControls));
            c.randomize && (a.slides.sort(function () {
                return Math.round(Math.random()) - 0.5
            }), a.container.empty().append(a.slides));
            a.doMath();
            t && f.asNav.setup();
            a.setup("init");
            c.controlNav && f.controlNav.setup();
            c.directionNav && f.directionNav.setup();
            c.keyboard &&
                (1 === d(a.containerSelector).length || c.multipleKeyboard) && d(document).bind("keyup", function (b) {
                b = b.keyCode;
                if (!a.animating && (39 === b || 37 === b))b = 39 === b ? a.getTarget("next") : 37 === b ? a.getTarget("prev") : !1, a.flexAnimate(b, c.pauseOnAction)
            });
            c.mousewheel && a.bind("mousewheel", function (b, g) {
                b.preventDefault();
                var d = 0 > g ? a.getTarget("next") : a.getTarget("prev");
                a.flexAnimate(d, c.pauseOnAction)
            });
            c.pausePlay && f.pausePlay.setup();
            c.slideshow && (c.pauseOnHover && a.hover(function () {
                    !a.manualPlay && !a.manualPause && a.pause()
                },
                function () {
                    !a.manualPause && !a.manualPlay && a.play()
                }), 0 < c.initDelay ? setTimeout(a.play, c.initDelay) : a.play());
            q && c.touch && f.touch();
            (!s || s && c.smoothHeight) && d(window).bind("resize focus", f.resize);
            setTimeout(function () {
                c.start(a)
            }, 200)
        }, asNav: {setup: function () {
            a.asNav = !0;
            a.animatingTo = Math.floor(a.currentSlide / a.move);
            a.currentItem = a.currentSlide;
            a.slides.removeClass(e + "active-slide").eq(a.currentItem).addClass(e + "active-slide");
            a.slides.click(function (b) {
                b.preventDefault();
                b = d(this);
                var g = b.index();
                !d(c.asNavFor).data("flexslider").animating && !b.hasClass("active") && (a.direction = a.currentItem < g ? "next" : "prev", a.flexAnimate(g, c.pauseOnAction, !1, !0, !0))
            })
        }}, controlNav: {setup: function () {
            a.manualControls ? f.controlNav.setupManual() : f.controlNav.setupPaging()
        }, setupPaging: function () {
            var b = 1, g;
            a.controlNavScaffold = d('<ol class="' + e + "control-nav " + e + ("thumbnails" === c.controlNav ? "control-thumbs" : "control-paging") + '"></ol>');
            if (1 < a.pagingCount)for (var p = 0; p < a.pagingCount; p++)g = "thumbnails" === c.controlNav ?
                '<img src="' + a.slides.eq(p).attr("data-thumb") + '"/>' : "<a>" + b + "</a>", a.controlNavScaffold.append("<li>" + g + "</li>"), b++;
            a.controlsContainer ? d(a.controlsContainer).append(a.controlNavScaffold) : a.append(a.controlNavScaffold);
            f.controlNav.set();
            f.controlNav.active();
            a.controlNavScaffold.delegate("a, img", u, function (b) {
                b.preventDefault();
                b = d(this);
                var g = a.controlNav.index(b);
                b.hasClass(e + "active") || (a.direction = g > a.currentSlide ? "next" : "prev", a.flexAnimate(g, c.pauseOnAction))
            });
            q && a.controlNavScaffold.delegate("a",
                "click touchstart", function (a) {
                    a.preventDefault()
                })
        }, setupManual: function () {
            a.controlNav = a.manualControls;
            f.controlNav.active();
            a.controlNav.live(u, function (b) {
                b.preventDefault();
                b = d(this);
                var g = a.controlNav.index(b);
                b.hasClass(e + "active") || (g > a.currentSlide ? a.direction = "next" : a.direction = "prev", a.flexAnimate(g, c.pauseOnAction))
            });
            q && a.controlNav.live("click touchstart", function (a) {
                a.preventDefault()
            })
        }, set: function () {
            a.controlNav = d("." + e + "control-nav li " + ("thumbnails" === c.controlNav ? "img" : "a"),
                a.controlsContainer ? a.controlsContainer : a)
        }, active: function () {
            a.controlNav.removeClass(e + "active").eq(a.animatingTo).addClass(e + "active")
        }, update: function (b, c) {
            1 < a.pagingCount && "add" === b ? a.controlNavScaffold.append(d("<li><a>" + a.count + "</a></li>")) : 1 === a.pagingCount ? a.controlNavScaffold.find("li").remove() : a.controlNav.eq(c).closest("li").remove();
            f.controlNav.set();
            1 < a.pagingCount && a.pagingCount !== a.controlNav.length ? a.update(c, b) : f.controlNav.active()
        }}, directionNav: {setup: function () {
            var b = d('<ul class="' +
                e + 'direction-nav"><li><a class="' + e + 'prev" href="#">' + c.prevText + '</a></li><li><a class="' + e + 'next" href="#">' + c.nextText + "</a></li></ul>");
            a.controlsContainer ? (d(a.controlsContainer).append(b), a.directionNav = d("." + e + "direction-nav li a", a.controlsContainer)) : (a.append(b), a.directionNav = d("." + e + "direction-nav li a", a));
            f.directionNav.update();
            a.directionNav.bind(u, function (b) {
                b.preventDefault();
                b = d(this).hasClass(e + "next") ? a.getTarget("next") : a.getTarget("prev");
                a.flexAnimate(b, c.pauseOnAction)
            });
            q && a.directionNav.bind("click touchstart", function (a) {
                a.preventDefault()
            })
        }, update: function () {
            var b = e + "disabled";
            1 === a.pagingCount ? a.directionNav.addClass(b) : c.animationLoop ? a.directionNav.removeClass(b) : 0 === a.animatingTo ? a.directionNav.removeClass(b).filter("." + e + "prev").addClass(b) : a.animatingTo === a.last ? a.directionNav.removeClass(b).filter("." + e + "next").addClass(b) : a.directionNav.removeClass(b)
        }}, pausePlay: {setup: function () {
            var b = d('<div class="' + e + 'pauseplay"><a></a></div>');
            a.controlsContainer ?
                (a.controlsContainer.append(b), a.pausePlay = d("." + e + "pauseplay a", a.controlsContainer)) : (a.append(b), a.pausePlay = d("." + e + "pauseplay a", a));
            f.pausePlay.update(c.slideshow ? e + "pause" : e + "play");
            a.pausePlay.bind(u, function (b) {
                b.preventDefault();
                d(this).hasClass(e + "pause") ? (a.manualPause = !0, a.manualPlay = !1, a.pause()) : (a.manualPause = !1, a.manualPlay = !0, a.play())
            });
            q && a.pausePlay.bind("click touchstart", function (a) {
                a.preventDefault()
            })
        }, update: function (b) {
            "play" === b ? a.pausePlay.removeClass(e + "pause").addClass(e +
                "play").text(c.playText) : a.pausePlay.removeClass(e + "play").addClass(e + "pause").text(c.pauseText)
        }}, touch: function () {
            function b(b) {
                k = m ? d - b.touches[0].pageY : d - b.touches[0].pageX;
                q = m ? Math.abs(k) < Math.abs(b.touches[0].pageX - e) : Math.abs(k) < Math.abs(b.touches[0].pageY - e);
                if (!q || 500 < Number(new Date) - l)b.preventDefault(), !s && a.transitions && (c.animationLoop || (k /= 0 === a.currentSlide && 0 > k || a.currentSlide === a.last && 0 < k ? Math.abs(k) / r + 2 : 1), a.setProps(f + k, "setTouch"))
            }

            function g() {
                j.removeEventListener("touchmove",
                    b, !1);
                if (a.animatingTo === a.currentSlide && !q && null !== k) {
                    var h = n ? -k : k, m = 0 < h ? a.getTarget("next") : a.getTarget("prev");
                    a.canAdvance(m) && (550 > Number(new Date) - l && 50 < Math.abs(h) || Math.abs(h) > r / 2) ? a.flexAnimate(m, c.pauseOnAction) : s || a.flexAnimate(a.currentSlide, c.pauseOnAction, !0)
                }
                j.removeEventListener("touchend", g, !1);
                f = k = e = d = null
            }

            var d, e, f, r, k, l, q = !1;
            j.addEventListener("touchstart", function (k) {
                a.animating ? k.preventDefault() : 1 === k.touches.length && (a.pause(), r = m ? a.h : a.w, l = Number(new Date), f = h && n && a.animatingTo ===
                    a.last ? 0 : h && n ? a.limit - (a.itemW + c.itemMargin) * a.move * a.animatingTo : h && a.currentSlide === a.last ? a.limit : h ? (a.itemW + c.itemMargin) * a.move * a.currentSlide : n ? (a.last - a.currentSlide + a.cloneOffset) * r : (a.currentSlide + a.cloneOffset) * r, d = m ? k.touches[0].pageY : k.touches[0].pageX, e = m ? k.touches[0].pageX : k.touches[0].pageY, j.addEventListener("touchmove", b, !1), j.addEventListener("touchend", g, !1))
            }, !1)
        }, resize: function () {
            !a.animating && a.is(":visible") && (h || a.doMath(), s ? f.smoothHeight() : h ? (a.slides.width(a.computedW),
                a.update(a.pagingCount), a.setProps()) : m ? (a.viewport.height(a.h), a.setProps(a.h, "setTotal")) : (c.smoothHeight && f.smoothHeight(), a.newSlides.width(a.computedW), a.setProps(a.computedW, "setTotal")))
        }, smoothHeight: function (b) {
            if (!m || s) {
                var c = s ? a : a.viewport;
                b ? c.animate({height: a.slides.eq(a.animatingTo).height()}, b) : c.height(a.slides.eq(a.animatingTo).height())
            }
        }, sync: function (b) {
            var g = d(c.sync).data("flexslider"), e = a.animatingTo;
            switch (b) {
                case "animate":
                    g.flexAnimate(e, c.pauseOnAction, !1, !0);
                    break;
                case "play":
                    !g.playing && !g.asNav && g.play();
                    break;
                case "pause":
                    g.pause()
            }
        }};
        a.flexAnimate = function (b, g, p, j, l) {
            t && 1 === a.pagingCount && (a.direction = a.currentItem < b ? "next" : "prev");
            if (!a.animating && (a.canAdvance(b, l) || p) && a.is(":visible")) {
                if (t && j)if (p = d(c.asNavFor).data("flexslider"), a.atEnd = 0 === b || b === a.count - 1, p.flexAnimate(b, !0, !1, !0, l), a.direction = a.currentItem < b ? "next" : "prev", p.direction = a.direction, Math.ceil((b + 1) / a.visible) - 1 !== a.currentSlide && 0 !== b)a.currentItem = b, a.slides.removeClass(e + "active-slide").eq(b).addClass(e +
                    "active-slide"), b = Math.floor(b / a.visible); else return a.currentItem = b, a.slides.removeClass(e + "active-slide").eq(b).addClass(e + "active-slide"), !1;
                a.animating = !0;
                a.animatingTo = b;
                c.before(a);
                g && a.pause();
                a.syncExists && !l && f.sync("animate");
                c.controlNav && f.controlNav.active();
                h || a.slides.removeClass(e + "active-slide").eq(b).addClass(e + "active-slide");
                a.atEnd = 0 === b || b === a.last;
                c.directionNav && f.directionNav.update();
                b === a.last && (c.end(a), c.animationLoop || a.pause());
                if (s)q ? (a.slides.eq(a.currentSlide).css({opacity: 0,
                    zIndex: 1}), a.slides.eq(b).css({opacity: 1, zIndex: 2}), a.slides.unbind("webkitTransitionEnd transitionend"), a.slides.eq(a.currentSlide).bind("webkitTransitionEnd transitionend", function () {
                    c.after(a)
                }), a.animating = !1, a.currentSlide = a.animatingTo) : (a.slides.eq(a.currentSlide).fadeOut(c.animationSpeed, c.easing), a.slides.eq(b).fadeIn(c.animationSpeed, c.easing, a.wrapup)); else {
                    var r = m ? a.slides.filter(":first").height() : a.computedW;
                    h ? (b = c.itemWidth > a.w ? 2 * c.itemMargin : c.itemMargin, b = (a.itemW + b) * a.move * a.animatingTo,
                        b = b > a.limit && 1 !== a.visible ? a.limit : b) : b = 0 === a.currentSlide && b === a.count - 1 && c.animationLoop && "next" !== a.direction ? n ? (a.count + a.cloneOffset) * r : 0 : a.currentSlide === a.last && 0 === b && c.animationLoop && "prev" !== a.direction ? n ? 0 : (a.count + 1) * r : n ? (a.count - 1 - b + a.cloneOffset) * r : (b + a.cloneOffset) * r;
                    a.setProps(b, "", c.animationSpeed);
                    if (a.transitions) {
                        if (!c.animationLoop || !a.atEnd)a.animating = !1, a.currentSlide = a.animatingTo;
                        a.container.unbind("webkitTransitionEnd transitionend");
                        a.container.bind("webkitTransitionEnd transitionend",
                            function () {
                                a.wrapup(r)
                            })
                    } else a.container.animate(a.args, c.animationSpeed, c.easing, function () {
                        a.wrapup(r)
                    })
                }
                c.smoothHeight && f.smoothHeight(c.animationSpeed)
            }
        };
        a.wrapup = function (b) {
            !s && !h && (0 === a.currentSlide && a.animatingTo === a.last && c.animationLoop ? a.setProps(b, "jumpEnd") : a.currentSlide === a.last && (0 === a.animatingTo && c.animationLoop) && a.setProps(b, "jumpStart"));
            a.animating = !1;
            a.currentSlide = a.animatingTo;
            c.after(a)
        };
        a.animateSlides = function () {
            a.animating || a.flexAnimate(a.getTarget("next"))
        };
        a.pause =
            function () {
                clearInterval(a.animatedSlides);
                a.playing = !1;
                c.pausePlay && f.pausePlay.update("play");
                a.syncExists && f.sync("pause")
            };
        a.play = function () {
            a.animatedSlides = setInterval(a.animateSlides, c.slideshowSpeed);
            a.playing = !0;
            c.pausePlay && f.pausePlay.update("pause");
            a.syncExists && f.sync("play")
        };
        a.canAdvance = function (b, g) {
            var d = t ? a.pagingCount - 1 : a.last;
            return g ? !0 : t && a.currentItem === a.count - 1 && 0 === b && "prev" === a.direction ? !0 : t && 0 === a.currentItem && b === a.pagingCount - 1 && "next" !== a.direction ? !1 : b === a.currentSlide && !t ? !1 : c.animationLoop ? !0 : a.atEnd && 0 === a.currentSlide && b === d && "next" !== a.direction ? !1 : a.atEnd && a.currentSlide === d && 0 === b && "next" === a.direction ? !1 : !0
        };
        a.getTarget = function (b) {
            a.direction = b;
            return"next" === b ? a.currentSlide === a.last ? 0 : a.currentSlide + 1 : 0 === a.currentSlide ? a.last : a.currentSlide - 1
        };
        a.setProps = function (b, g, d) {
            var e, f = b ? b : (a.itemW + c.itemMargin) * a.move * a.animatingTo;
            e = -1 * function () {
                if (h)return"setTouch" === g ? b : n && a.animatingTo === a.last ? 0 : n ? a.limit - (a.itemW + c.itemMargin) * a.move * a.animatingTo : a.animatingTo ===
                    a.last ? a.limit : f;
                switch (g) {
                    case "setTotal":
                        return n ? (a.count - 1 - a.currentSlide + a.cloneOffset) * b : (a.currentSlide + a.cloneOffset) * b;
                    case "setTouch":
                        return b;
                    case "jumpEnd":
                        return n ? b : a.count * b;
                    case "jumpStart":
                        return n ? a.count * b : b;
                    default:
                        return b
                }
            }() + "px";
            a.transitions && (e = m ? "translate3d(0," + e + ",0)" : "translate3d(" + e + ",0,0)", d = void 0 !== d ? d / 1E3 + "s" : "0s", a.container.css("-" + a.pfx + "-transition-duration", d));
            a.args[a.prop] = e;
            (a.transitions || void 0 === d) && a.container.css(a.args)
        };
        a.setup = function (b) {
            if (s)a.slides.css({width: "100%",
                "float": "left", marginRight: "-100%", position: "relative"}), "init" === b && (q ? a.slides.css({opacity: 0, display: "block", webkitTransition: "opacity " + c.animationSpeed / 1E3 + "s ease", zIndex: 1}).eq(a.currentSlide).css({opacity: 1, zIndex: 2}) : a.slides.eq(a.currentSlide).fadeIn(c.animationSpeed, c.easing)), c.smoothHeight && f.smoothHeight(); else {
                var g, p;
                "init" === b && (a.viewport = d('<div class="' + e + 'viewport"></div>').css({overflow: "hidden", position: "relative"}).appendTo(a).append(a.container), a.cloneCount = 0, a.cloneOffset =
                    0, n && (p = d.makeArray(a.slides).reverse(), a.slides = d(p), a.container.empty().append(a.slides)));
                c.animationLoop && !h && (a.cloneCount = 2, a.cloneOffset = 1, "init" !== b && a.container.find(".clone").remove(), a.container.append(a.slides.first().clone().addClass("clone")).prepend(a.slides.last().clone().addClass("clone")));
                a.newSlides = d(c.selector, a);
                g = n ? a.count - 1 - a.currentSlide + a.cloneOffset : a.currentSlide + a.cloneOffset;
                m && !h ? (a.container.height(200 * (a.count + a.cloneCount) + "%").css("position", "absolute").width("100%"),
                    setTimeout(function () {
                        a.newSlides.css({display: "block"});
                        a.doMath();
                        a.viewport.height(a.h);
                        a.setProps(g * a.h, "init")
                    }, "init" === b ? 100 : 0)) : (a.container.width(200 * (a.count + a.cloneCount) + "%"), a.setProps(g * a.computedW, "init"), setTimeout(function () {
                    a.doMath();
                    a.newSlides.css({width: a.computedW, "float": "left", display: "block"});
                    c.smoothHeight && f.smoothHeight()
                }, "init" === b ? 100 : 0))
            }
            h || a.slides.removeClass(e + "active-slide").eq(a.currentSlide).addClass(e + "active-slide")
        };
        a.doMath = function () {
            var b = a.slides.first(),
                d = c.itemMargin, e = c.minItems, f = c.maxItems;
            a.w = a.width();
            a.h = b.height();
            a.boxPadding = b.outerWidth() - b.width();
            h ? (a.itemT = c.itemWidth + d, a.minW = e ? e * a.itemT : a.w, a.maxW = f ? f * a.itemT : a.w, a.itemW = a.minW > a.w ? (a.w - d * e) / e : a.maxW < a.w ? (a.w - d * f) / f : c.itemWidth > a.w ? a.w : c.itemWidth, a.visible = Math.floor(a.w / (a.itemW + d)), a.move = 0 < c.move && c.move < a.visible ? c.move : a.visible, a.pagingCount = Math.ceil((a.count - a.visible) / a.move + 1), a.last = a.pagingCount - 1, a.limit = 1 === a.pagingCount ? 0 : c.itemWidth > a.w ? (a.itemW + 2 * d) * a.count - a.w -
                d : (a.itemW + d) * a.count - a.w - d) : (a.itemW = a.w, a.pagingCount = a.count, a.last = a.count - 1);
            a.computedW = a.itemW - a.boxPadding
        };
        a.update = function (b, d) {
            a.doMath();
            h || (b < a.currentSlide ? a.currentSlide += 1 : b <= a.currentSlide && 0 !== b && (a.currentSlide -= 1), a.animatingTo = a.currentSlide);
            if (c.controlNav && !a.manualControls)if ("add" === d && !h || a.pagingCount > a.controlNav.length)f.controlNav.update("add"); else if ("remove" === d && !h || a.pagingCount < a.controlNav.length)h && a.currentSlide > a.last && (a.currentSlide -= 1, a.animatingTo -= 1),
                f.controlNav.update("remove", a.last);
            c.directionNav && f.directionNav.update()
        };
        a.addSlide = function (b, e) {
            var f = d(b);
            a.count += 1;
            a.last = a.count - 1;
            m && n ? void 0 !== e ? a.slides.eq(a.count - e).after(f) : a.container.prepend(f) : void 0 !== e ? a.slides.eq(e).before(f) : a.container.append(f);
            a.update(e, "add");
            a.slides = d(c.selector + ":not(.clone)", a);
            a.setup();
            c.added(a)
        };
        a.removeSlide = function (b) {
            var e = isNaN(b) ? a.slides.index(d(b)) : b;
            a.count -= 1;
            a.last = a.count - 1;
            isNaN(b) ? d(b, a.slides).remove() : m && n ? a.slides.eq(a.last).remove() :
                a.slides.eq(b).remove();
            a.doMath();
            a.update(e, "remove");
            a.slides = d(c.selector + ":not(.clone)", a);
            a.setup();
            c.removed(a)
        };
        f.init()
    };
    d.flexslider.defaults = {namespace: "flex-", selector: ".slides > li", animation: "fade", easing: "swing", direction: "horizontal", reverse: !1, animationLoop: !0, smoothHeight: !1, startAt: 0, slideshow: !0, slideshowSpeed: 7E3, animationSpeed: 600, initDelay: 0, randomize: !1, pauseOnAction: !0, pauseOnHover: !1, useCSS: !0, touch: !0, video: !1, controlNav: !0, directionNav: !0, prevText: "Previous", nextText: "Next",
        keyboard: !0, multipleKeyboard: !1, mousewheel: !1, pausePlay: !1, pauseText: "Pause", playText: "Play", controlsContainer: "", manualControls: "", sync: "", asNavFor: "", itemWidth: 0, itemMargin: 0, minItems: 0, maxItems: 0, move: 0, start: function () {
        }, before: function () {
        }, after: function () {
        }, end: function () {
        }, added: function () {
        }, removed: function () {
        }};
    d.fn.flexslider = function (j) {
        void 0 === j && (j = {});
        if ("object" === typeof j)return this.each(function () {
            var a = d(this), c = a.find(j.selector ? j.selector : ".slides > li");
            1 === c.length ? (c.fadeIn(400),
                j.start && j.start(a)) : void 0 == a.data("flexslider") && new d.flexslider(this, j)
        });
        var l = d(this).data("flexslider");
        switch (j) {
            case "play":
                l.play();
                break;
            case "pause":
                l.pause();
                break;
            case "next":
                l.flexAnimate(l.getTarget("next"), !0);
                break;
            case "prev":
            case "previous":
                l.flexAnimate(l.getTarget("prev"), !0);
                break;
            default:
                "number" === typeof j && l.flexAnimate(j, !0)
        }
    }
})(jQuery);


/*!
 * jQuery MeanMenu v2.0.6
 * @Copyright (C) 2012-2013 Chris Wharton (https://github.com/weare2ndfloor/meanMenu)
 */
!function (e) {
    "use strict";
    e.fn.meanmenu = function (n) {
        var a = {meanMenuTarget: jQuery(this), meanMenuContainer: "body", meanMenuClose: "<span />", meanMenuCloseSize: "18px", meanMenuOpen: "<span />", meanRevealPosition: "right", meanRevealPositionDistance: "0", meanRevealColour: "", meanRevealHoverColour: "", meanScreenWidth: "768", meanNavPush: "", meanShowChildren: !0, meanExpandableChildren: !0, meanExpand: "", meanContract: "", meanRemoveAttrs: !1, onePage: !1, removeElements: ""}, n = e.extend(a, n), t = window.innerWidth || document.documentElement.clientWidth;
        return this.each(function () {
            function e() {
                if ("center" == c) {
                    var e = window.innerWidth || document.documentElement.clientWidth, n = e / 2 - 22 + "px";
                    P = "left:" + n + ";right:auto;", A ? jQuery(".meanmenu-reveal").animate({left: n}) : jQuery(".meanmenu-reveal").css("left", n)
                }
            }

            function a() {
                jQuery(W).is(".meanmenu-reveal.meanclose") ? W.html(o) : W.html(s)
            }

            function r() {
                jQuery(".mean-bar,.mean-push").remove(), jQuery(m).removeClass("mean-container"), jQuery(u).show(), E = !1, M = !1, jQuery(x).removeClass("mean-remove")
            }

            function i() {
                if (d >= t) {
                    jQuery(x).addClass("mean-remove"), M = !0, jQuery(m).addClass("mean-container"), jQuery(".mean-container").prepend('<div class="mean-bar"><a href="#nav" class="meanmenu-reveal" style="' + R + '">Show Navigation</a><nav class="mean-nav"></nav></div>');
                    var e = jQuery(u).html();
                    jQuery(".mean-nav").html(e), C && jQuery("nav.mean-nav ul, nav.mean-nav ul *").each(function () {
                        jQuery(this).removeAttr("class"), jQuery(this).removeAttr("id")
                    }), jQuery(u).before('<div class="mean-push" />'), jQuery(".mean-push").css("margin-top", y), jQuery(u).hide(), jQuery(".meanmenu-reveal").show(), jQuery(j).html(s), W = jQuery(j), jQuery(".mean-nav ul").hide(), Q ? f ? (jQuery(".mean-nav ul ul").each(function () {
                        jQuery(this).children().length && jQuery(this, "li:first").parent().append('<a class="mean-expand" href="#" style="font-size: ' + l + '">' + g + "</a>")
                    }), jQuery(".mean-expand").on("click", function (e) {
                        e.preventDefault(), jQuery(this).hasClass("mean-clicked") ? (jQuery(this).text(g), jQuery(this).prev("ul").slideUp(300, function () {
                        })) : (jQuery(this).text(p), jQuery(this).prev("ul").slideDown(300, function () {
                        })), jQuery(this).toggleClass("mean-clicked")
                    })) : jQuery(".mean-nav ul ul").show() : jQuery(".mean-nav ul ul").hide(), jQuery(".mean-nav ul li").last().addClass("mean-last"), W.removeClass("meanclose"), jQuery(W).click(function (e) {
                        e.preventDefault(), 0 == E ? (W.css("text-align", "center"), W.css("text-indent", "0"), W.css("font-size", l), jQuery(".mean-nav ul:first").slideDown(), E = !0) : (jQuery(".mean-nav ul:first").slideUp(), E = !1), W.toggleClass("meanclose"), a(), jQuery(x).addClass("mean-remove")
                    }), w && jQuery(".mean-nav ul > li > a:first-child").on("click", function () {
                        jQuery(".mean-nav ul:first").slideUp(), E = !1, jQuery(W).toggleClass("meanclose").html(s)
                    })
                } else r()
            }

            var u = n.meanMenuTarget, m = n.meanMenuContainer;
            n.meanReveal;
            var o = n.meanMenuClose, l = n.meanMenuCloseSize, s = n.meanMenuOpen, c = n.meanRevealPosition, v = n.meanRevealPositionDistance, h = n.meanRevealColour;
            n.meanRevealHoverColour;
            var d = n.meanScreenWidth, y = n.meanNavPush, j = ".meanmenu-reveal", Q = n.meanShowChildren, f = n.meanExpandableChildren, g = n.meanExpand, p = n.meanContract, C = n.meanRemoveAttrs, w = n.onePage, x = n.removeElements;
            if (navigator.userAgent.match(/iPhone/i) || navigator.userAgent.match(/iPod/i) || navigator.userAgent.match(/iPad/i) || navigator.userAgent.match(/Android/i) || navigator.userAgent.match(/Blackberry/i) || navigator.userAgent.match(/Windows Phone/i))var A = !0;
            (navigator.userAgent.match(/MSIE 8/i) || navigator.userAgent.match(/MSIE 7/i)) && jQuery("html").css("overflow-y", "scroll");
            var E = !1, M = !1;
            if ("right" == c && (P = "right:" + v + ";left:auto;"), "left" == c)var P = "left:" + v + ";right:auto;";
            e();
            var R = "background:" + h + ";color:" + h + ";" + P, W = "";
            A || jQuery(window).resize(function () {
                t = window.innerWidth || document.documentElement.clientWidth, t > d ? r() : r(), d >= t ? (i(), e()) : r()
            }), window.onorientationchange = function () {
                e(), t = window.innerWidth || document.documentElement.clientWidth, t >= d && r(), d >= t && 0 == M && i()
            }, i()
        })
    }
}(jQuery);


/*!
 * Bootstrap v3.0.0
 *
 * Copyright 2013 Twitter, Inc
 * Licensed under the Apache License v2.0
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Designed and built with all the love in the world @twitter by @mdo and @fat.
 */

!function (a) {
    "use strict";
    var b = function (a, b) {
        this.type = this.options = this.enabled = this.timeout = this.hoverState = this.$element = null, this.init("tooltip", a, b)
    };
    b.DEFAULTS = {animation: !0, placement: "top", selector: !1, template: '<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>', trigger: "hover focus", title: "", delay: 0, html: !1, container: !1}, b.prototype.init = function (b, c, d) {
        this.enabled = !0, this.type = b, this.$element = a(c), this.options = this.getOptions(d);
        var e = this.options.trigger.split(" ");
        for (var f = e.length; f--;) {
            var g = e[f];
            if (g == "click")this.$element.on("click." + this.type, this.options.selector, a.proxy(this.toggle, this)); else if (g != "manual") {
                var h = g == "hover" ? "mouseenter" : "focus", i = g == "hover" ? "mouseleave" : "blur";
                this.$element.on(h + "." + this.type, this.options.selector, a.proxy(this.enter, this)), this.$element.on(i + "." + this.type, this.options.selector, a.proxy(this.leave, this))
            }
        }
        this.options.selector ? this._options = a.extend({}, this.options, {trigger: "manual", selector: ""}) : this.fixTitle()
    }, b.prototype.getDefaults = function () {
        return b.DEFAULTS
    }, b.prototype.getOptions = function (b) {
        return b = a.extend({}, this.getDefaults(), this.$element.data(), b), b.delay && typeof b.delay == "number" && (b.delay = {show: b.delay, hide: b.delay}), b
    }, b.prototype.getDelegateOptions = function () {
        var b = {}, c = this.getDefaults();
        return this._options && a.each(this._options, function (a, d) {
            c[a] != d && (b[a] = d)
        }), b
    }, b.prototype.enter = function (b) {
        var c = b instanceof this.constructor ? b : a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type);
        clearTimeout(c.timeout), c.hoverState = "in";
        if (!c.options.delay || !c.options.delay.show)return c.show();
        c.timeout = setTimeout(function () {
            c.hoverState == "in" && c.show()
        }, c.options.delay.show)
    }, b.prototype.leave = function (b) {
        var c = b instanceof this.constructor ? b : a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type);
        clearTimeout(c.timeout), c.hoverState = "out";
        if (!c.options.delay || !c.options.delay.hide)return c.hide();
        c.timeout = setTimeout(function () {
            c.hoverState == "out" && c.hide()
        }, c.options.delay.hide)
    }, b.prototype.show = function () {
        var b = a.Event("show.bs." + this.type);
        if (this.hasContent() && this.enabled) {
            this.$element.trigger(b);
            if (b.isDefaultPrevented())return;
            var c = this.tip();
            this.setContent(), this.options.animation && c.addClass("fade");
            var d = typeof this.options.placement == "function" ? this.options.placement.call(this, c[0], this.$element[0]) : this.options.placement, e = /\s?auto?\s?/i, f = e.test(d);
            f && (d = d.replace(e, "") || "top"), c.detach().css({top: 0, left: 0, display: "block"}).addClass(d), this.options.container ? c.appendTo(this.options.container) : c.insertAfter(this.$element);
            var g = this.getPosition(), h = c[0].offsetWidth, i = c[0].offsetHeight;
            if (f) {
                var j = this.$element.parent(), k = d, l = document.documentElement.scrollTop || document.body.scrollTop, m = this.options.container == "body" ? window.innerWidth : j.outerWidth(), n = this.options.container == "body" ? window.innerHeight : j.outerHeight(), o = this.options.container == "body" ? 0 : j.offset().left;
                d = d == "bottom" && g.top + g.height + i - l > n ? "top" : d == "top" && g.top - l - i < 0 ? "bottom" : d == "right" && g.right + h > m ? "left" : d == "left" && g.left - h < o ? "right" : d, c.removeClass(k).addClass(d)
            }
            var p = this.getCalculatedOffset(d, g, h, i);
            this.applyPlacement(p, d), this.$element.trigger("shown.bs." + this.type)
        }
    }, b.prototype.applyPlacement = function (a, b) {
        var c, d = this.tip(), e = d[0].offsetWidth, f = d[0].offsetHeight, g = parseInt(d.css("margin-top"), 10), h = parseInt(d.css("margin-left"), 10);
        isNaN(g) && (g = 0), isNaN(h) && (h = 0), a.top = a.top + g, a.left = a.left + h, d.offset(a).addClass("in");
        var i = d[0].offsetWidth, j = d[0].offsetHeight;
        b == "top" && j != f && (c = !0, a.top = a.top + f - j);
        if (/bottom|top/.test(b)) {
            var k = 0;
            a.left < 0 && (k = a.left * -2, a.left = 0, d.offset(a), i = d[0].offsetWidth, j = d[0].offsetHeight), this.replaceArrow(k - e + i, i, "left")
        } else this.replaceArrow(j - f, j, "top");
        c && d.offset(a)
    }, b.prototype.replaceArrow = function (a, b, c) {
        this.arrow().css(c, a ? 50 * (1 - a / b) + "%" : "")
    }, b.prototype.setContent = function () {
        var a = this.tip(), b = this.getTitle();
        a.find(".tooltip-inner")[this.options.html ? "html" : "text"](b), a.removeClass("fade in top bottom left right")
    }, b.prototype.hide = function () {
        function e() {
            b.hoverState != "in" && c.detach()
        }

        var b = this, c = this.tip(), d = a.Event("hide.bs." + this.type);
        this.$element.trigger(d);
        if (d.isDefaultPrevented())return;
        return c.removeClass("in"), a.support.transition && this.$tip.hasClass("fade") ? c.one(a.support.transition.end, e).emulateTransitionEnd(150) : e(), this.$element.trigger("hidden.bs." + this.type), this
    }, b.prototype.fixTitle = function () {
        var a = this.$element;
        (a.attr("title") || typeof a.attr("data-original-title") != "string") && a.attr("data-original-title", a.attr("title") || "").attr("title", "")
    }, b.prototype.hasContent = function () {
        return this.getTitle()
    }, b.prototype.getPosition = function () {
        var b = this.$element[0];
        return a.extend({}, typeof b.getBoundingClientRect == "function" ? b.getBoundingClientRect() : {width: b.offsetWidth, height: b.offsetHeight}, this.$element.offset())
    }, b.prototype.getCalculatedOffset = function (a, b, c, d) {
        return a == "bottom" ? {top: b.top + b.height, left: b.left + b.width / 2 - c / 2} : a == "top" ? {top: b.top - d, left: b.left + b.width / 2 - c / 2} : a == "left" ? {top: b.top + b.height / 2 - d / 2, left: b.left - c} : {top: b.top + b.height / 2 - d / 2, left: b.left + b.width}
    }, b.prototype.getTitle = function () {
        var a, b = this.$element, c = this.options;
        return a = b.attr("data-original-title") || (typeof c.title == "function" ? c.title.call(b[0]) : c.title), a
    }, b.prototype.tip = function () {
        return this.$tip = this.$tip || a(this.options.template)
    }, b.prototype.arrow = function () {
        return this.$arrow = this.$arrow || this.tip().find(".tooltip-arrow")
    }, b.prototype.validate = function () {
        this.$element[0].parentNode || (this.hide(), this.$element = null, this.options = null)
    }, b.prototype.enable = function () {
        this.enabled = !0
    }, b.prototype.disable = function () {
        this.enabled = !1
    }, b.prototype.toggleEnabled = function () {
        this.enabled = !this.enabled
    }, b.prototype.toggle = function (b) {
        var c = b ? a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs." + this.type) : this;
        c.tip().hasClass("in") ? c.leave(c) : c.enter(c)
    }, b.prototype.destroy = function () {
        this.hide().$element.off("." + this.type).removeData("bs." + this.type)
    };
    var c = a.fn.tooltip;
    a.fn.tooltip = function (c) {
        return this.each(function () {
            var d = a(this), e = d.data("bs.tooltip"), f = typeof c == "object" && c;
            e || d.data("bs.tooltip", e = new b(this, f)), typeof c == "string" && e[c]()
        })
    }, a.fn.tooltip.Constructor = b, a.fn.tooltip.noConflict = function () {
        return a.fn.tooltip = c, this
    }
}(window.jQuery), +function (a) {
    "use strict";
    var b = function (a, b) {
        this.init("popover", a, b)
    };
    if (!a.fn.tooltip)throw new Error("Popover requires tooltip.js");
    b.DEFAULTS = a.extend({}, a.fn.tooltip.Constructor.DEFAULTS, {placement: "right", trigger: "click", content: "", template: '<div class="popover"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}), b.prototype = a.extend({}, a.fn.tooltip.Constructor.prototype), b.prototype.constructor = b, b.prototype.getDefaults = function () {
        return b.DEFAULTS
    }, b.prototype.setContent = function () {
        var a = this.tip(), b = this.getTitle(), c = this.getContent();
        a.find(".popover-title")[this.options.html ? "html" : "text"](b), a.find(".popover-content")[this.options.html ? "html" : "text"](c), a.removeClass("fade top bottom left right in"), a.find(".popover-title").html() || a.find(".popover-title").hide()
    }, b.prototype.hasContent = function () {
        return this.getTitle() || this.getContent()
    }, b.prototype.getContent = function () {
        var a = this.$element, b = this.options;
        return a.attr("data-content") || (typeof b.content == "function" ? b.content.call(a[0]) : b.content)
    }, b.prototype.arrow = function () {
        return this.$arrow = this.$arrow || this.tip().find(".arrow")
    }, b.prototype.tip = function () {
        return this.$tip || (this.$tip = a(this.options.template)), this.$tip
    };
    var c = a.fn.popover;
    a.fn.popover = function (c) {
        return this.each(function () {
            var d = a(this), e = d.data("bs.popover"), f = typeof c == "object" && c;
            e || d.data("bs.popover", e = new b(this, f)), typeof c == "string" && e[c]()
        })
    }, a.fn.popover.Constructor = b, a.fn.popover.noConflict = function () {
        return a.fn.popover = c, this
    }
}(window.jQuery)
